You are viewing a plain text version of this content. The canonical link for it is here.
Posted to bugs@apr.apache.org by bu...@apache.org on 2007/08/21 17:00:03 UTC
DO NOT REPLY [Bug 43178] New: - apr_shm_create incorrect comparison of ERROR_ALREADY_EXISTS
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=43178>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=43178
Summary: apr_shm_create incorrect comparison of
ERROR_ALREADY_EXISTS
Product: APR
Version: 1.2.8
Platform: PC
OS/Version: Windows XP
Status: NEW
Severity: major
Priority: P2
Component: APR
AssignedTo: bugs@apr.apache.org
ReportedBy: sobekjunk@gmail.com
Line 136 of shm.c has the following comparison:
if (hMap && err == ERROR_ALREADY_EXISTS) {
CloseHandle(hMap);
return APR_EEXIST;
}
Should be:
if (hMap && APR_STATUS_IS_EEXIST(err)) {
CloseHandle(hMap);
return APR_EEXIST;
}
Since apr_get_os_error() returns e + APR_OS_START_SYSERR the return of
ERROR_ALREADY_EXISTS changes to, for windows, 720183 which does not equal 183L
as defined in winerror.h. The defined macro for IS_EEXIST compares the error
against the correct values. As the code is now, attempting to create shmem
that already exists will return success.
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@apr.apache.org
For additional commands, e-mail: bugs-help@apr.apache.org
DO NOT REPLY [Bug 43178] - apr_shm_create incorrect comparison of ERROR_ALREADY_EXISTS
Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=43178>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=43178
wrowe@apache.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
------- Additional Comments From wrowe@apache.org 2007-08-27 18:25 -------
Fixed in r570289 and backported to 1.2/0.9 for the next release.
Good catch; thanks for the report!
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@apr.apache.org
For additional commands, e-mail: bugs-help@apr.apache.org