Subject: standards/10791: _POSIX_SOURCE vs. sys/socket.h
To: None <gnats-bugs@gnats.netbsd.org>
From: None <wiz@danbala.tuwien.ac.at>
List: netbsd-bugs
Date: 08/09/2000 04:50:12
>Number: 10791
>Category: standards
>Synopsis: _POSIX_SOURCE vs. sys/socket.h
>Confidential: no
>Severity: serious
>Priority: low
>Responsible: standards-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Aug 09 04:51:00 PDT 2000
>Closed-Date:
>Last-Modified:
>Originator: Wiz
>Release: 1.5C of 2000/07/30
>Organization:
>Environment:
System: NetBSD hiro 1.5C NetBSD 1.5C (HIRO) #5: Sun Jul 30 23:02:28 CEST 2000 wiz@hiro:/archive/cvs/src/sys-i4b/arch/i386/compile/HIRO i386
>Description:
Defining _POSIX_SOURCE and including sys/socket.h fails.
>How-To-Repeat:
Compile the following program:
#define _POSIX_SOURCE
#include <sys/types.h>
#include <sys/socket.h>
int main() {
return 0;
}
Compilation fails with:
In file included from test.c:3:
/usr/include/sys/socket.h:192: syntax error before `u_char'
/usr/include/sys/socket.h:220: syntax error before `u_char'
/usr/include/sys/socket.h:222: `u_char' undeclared here (not in a function)
/usr/include/sys/socket.h:224: `u_char' undeclared here (not in a function)
/usr/include/sys/socket.h:224: `u_char' undeclared here (not in a function)
/usr/include/sys/socket.h:458: syntax error before `u_short'
>Fix:
None provided.
This is mainly a reminder PR for Klaus Klein, who said he would take
care of it.
>Release-Note:
>Audit-Trail:
>Unformatted: