Closed
Bug 52396
Opened 24 years ago
Closed 24 years ago
nss/lib/ssl/unix_err.c should check for ENOSR before using it
Categories
(NSS :: Libraries, defect, P3)
Tracking
(Not tracked)
RESOLVED
FIXED
3.1
People
(Reporter: tstromberg, Assigned: nelson)
References
()
Details
build under FreeBSD 5 breaks here: unix_err.c: In function Nss_MD_unix_map_default_error': unix_err.c:508: ENOSR' undeclared (first use in this function) unix_err.c:508: (Each undeclared identifier is reported only once unix_err.c:508: for each function it appears in.) gmake[2]: *** [FreeBSD5.0_DBG.OBJ/unix_err.o] Error 1 gmake[2]: Leaving directory /usr/src/moz-crypto/mozilla/security/nss/lib/ssl' gmake[1]: *** [libs] Error 2 gmake[1]: Leaving directory /usr/src/moz-crypto/mozilla/security/nss/lib' gmake: *** [libs] Error 2 because ENOSR is not defined in BSD (SYSV streams) and not checked for.. patch is: --- /usr/src/moz-crypto/mozilla/security/nss/lib/ssl/unix_err.c~ Fri Mar 31 14:37:17 2000 +++ /usr/src/moz-crypto/mozilla/security/nss/lib/ssl/unix_err.c Wed Sep 13 00:25:10 2000 @@ -505,7 +505,9 @@ case ENOMEM: prError = PR_OUT_OF_MEMORY_ERROR; break; case ENOPROTOOPT: prError = PR_INVALID_ARGUMENT_ERROR; break; case ENOSPC: prError = PR_NO_DEVICE_SPACE_ERROR; break; +#ifdef ENOSR case ENOSR: prError = PR_INSUFFICIENT_RESOURCES_ERROR; break; +#endif case ENOTCONN: prError = PR_NOT_CONNECTED_ERROR; break; case ENOTDIR: prError = PR_NOT_DIRECTORY_ERROR; break; case ENOTSOCK: prError = PR_NOT_SOCKET_ERROR; break;
Assignee | ||
Comment 1•24 years ago
|
||
This code more-or-less duplicates a static function in NSPR. Does NSPR also have this problem? The right fix, IMO, would be for NSPR to export that function, so it wouldn't have to be duplicated for every layered protocol, as it must be now.
Assignee: wtc → nelsonb
Status: UNCONFIRMED → NEW
Ever confirmed: true
Target Milestone: --- → 3.1
Assignee | ||
Comment 2•24 years ago
|
||
Fixed in rev 1.2 of unix_err.c on the trunk (NSS 3.1).
Status: NEW → RESOLVED
Closed: 24 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•