Subject: standards/21411: POSIX.1-2001: struct netent.n_net has wrong type
To: None <gnats-bugs@gnats.netbsd.org>
From: Ben Harris <bjh21@netbsd.org>
List: netbsd-bugs
Date: 05/01/2003 13:50:10
>Number:         21411
>Category:       standards
>Synopsis:       POSIX.1-2001: <netdb.h> struct netent.n_net has wrong type
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    standards-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu May 01 12:51:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     Ben Harris
>Release:        2003-05-01
>Organization:
>Environment:
>Description:
IEEE Std 1003.1-2001 and XNS5 both define struct netent to have the
following members:

char	*n_name
char	**n_aliases
int	n_addrtype
uint32_t n_net

NetBSD, though, defines n_net to be unsigned long.  This is a problem on
LP64 platforms.

>How-To-Repeat:
Inspection of <netdb.h> and comparison with
<http://www.opengroup.org/onlinepubs/007904975/basedefs/netdb.h.html>

>Fix:
All functions handing netents will need to be versioned.



>Release-Note:
>Audit-Trail:
>Unformatted: