NSPR 4.0 is not backward compatible with NSPR 3.x releases. The modifications in
NSPR 4.0 that affect backward compatibility are:
1. PR_Bind doesn't set the reuseaddr option - requires source-code modification
2. PRIOMethods is modified - recompilation required
3. Deletion of obsolete APIs - requires source-code modification. These APIs are
not widely used and so, many applications will not be affected.
4. Library name change from libnspr3.so to libpsr4.so - requires change to
configuration/makefiles for the clients
5. PR_NewTCPSocket doesn't set the SO_KEEPALIVE socket option - may require
source-code change to the client.
A set of obsolete APIs, listed in Bugzilla 23642, will be deleted.
The WINNT and WIN95 implementations of PR_OpenSemaphore
and PR_OpenSharedMemory were changed to implement the
'mode' argument on Windows NT using NT security descriptors
and discretionary access-control lists. (See Bugzilla
The size of PRNetAddr increased from 16 to 28 bytes
on non-Unix platforms.
In particular, the buffer passed to PR_AcceptRead
may need to be enlarged because of the larger
PRNetAddr size. I'm still looking into this.
Because we try to align the _pr_in6_addr structure on
8-byte boundary, the size of PRNetAddr is 32 (rather
than 28) bytes on Windows.
To help users of the PR_AcceptRead() function correctly specify the buffer size
for the read, a macro: PR_ACCEPT_READ_BUF_OVERHEAD is defined. An example also
suggests use of the macro in calculating buffer size and use with
/cvsroot/mozilla/nsprpub/pr/include/prio.h,v <-- prio.h
new revision: 184.108.40.206; previous revision: 220.127.116.11
The macro 'PR_NetAddrInetPort' is modified to check for the PR_AF_INET6 family
on all platforms. Bugzilla 23815.