Last Comment Bug 504248 - Request removal of #include <rpc/types.h> from prinet.h
: Request removal of #include <rpc/types.h> from prinet.h
Status: NEW
Product: NSPR
Classification: Components
Component: NSPR (show other bugs)
: 4.8
: All FreeBSD
-- enhancement (vote)
: ---
Assigned To: Nelson Bolyard (seldom reads bugmail)
Depends on:
  Show dependency treegraph
Reported: 2009-07-14 21:21 PDT by Nelson Bolyard (seldom reads bugmail)
Modified: 2012-02-29 06:03 PST (History)
4 users (show)
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---


Description User image Nelson Bolyard (seldom reads bugmail) 2009-07-14 21:21:41 PDT
NSPR's internal header file pr/include/md/_freebsd.h includes these lines,
which go all the way back to rev 1.1:

  /* freebsd has INADDR_LOOPBACK defined, but in /usr/include/rpc/types.h, 
     and I didn't want to be including that.. */
  #define INADDR_LOOPBACK         (u_long)0x7F000001

But NSPR's public header file prinet.h contains these lines:

  #if defined(FREEBSD) || defined(BSDI) || defined(QNX)
  #include <rpc/types.h> /* the only place that defines INADDR_LOOPBACK */

This inconsistency is odd.  NSPR makes its users include a file that it 
does not always include itself.  

Sun's NSPR/NSS team has received a request to change prinet.h to use the 
same #define technique as used in _freebsd.h, rather than continuing to 
#include <rpc/types.h> to resolve some issues with the file rpc/types.h 
in recent versions of FreeBSD.

Here, I want to ask the NSPR developers: Is this a reasonable request?
Wan-Teh, what's your opinion?
Comment 1 User image Wan-Teh Chang 2009-07-29 14:07:36 PDT
This is fine.
Comment 2 User image Phoenix 2012-02-29 06:03:03 PST
Is this still actual?

Note You need to log in before you can comment on or make changes to this bug.