Skip site navigation (1)Skip section navigation (2)
Date:      28 Jun 2002 11:06:47 +0000
From:      Christopher Nehren <apeiron@prophecy.dyndns.org>
To:        freebsd-bugs@freebsd.org
Subject:   Syntax errors in netinet6/in6.h and sys/socket.h
Message-ID:  <1025262407.272.78.camel@prophecy.dyndns.org>

next in thread | raw e-mail | index | archive | help
>Synopsis:       4.6R has errors in net header files
>Confidential:   no
>Severity:       serious
>Priority:       I'm guessing high, lots of stuff uses socket.h, no?
>Responsible:    freebsd-bugs
>State:          open
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Jun 2 14:00:05 PDT 2002
>Last-Modified:
>Originator:     Chris Nehren
>Environment:
FreeBSD prophecy.dyndns.org 4.6-RELEASE FreeBSD 4.6-RELEASE #0: Tue Jun
25 11:28:04 GMT 2002    
root@prophecy.dyndns.org:/usr/obj/usr/src/sys/PROPHECY  i386


>Description:
Including <sys/socket.h> and <netinet/in.h> produces syntax errors even
with an empty program

>How-To-Repeat:

Compile the C program that follows:
#include <sys/socket.h>
#include <netinet/in.h> 
/* can't include <netinet6/in6.h> directly */
int main()
{
return 0;
}

>Output:
--- begin paste ---
/usr/include/sys/socket.h:52: syntax error before `sa_family_t'
/usr/include/sys/socket.h:52: warning: data definition has no type or storage class
/usr/include/sys/socket.h:163: syntax error before `u_char'
/usr/include/sys/socket.h:174: syntax error before `u_short'
/usr/include/sys/socket.h:188: syntax error before `u_char'
/usr/include/sys/socket.h:190: `int64_t' undeclared here (not in a function)
/usr/include/sys/socket.h:190: `u_char' undeclared here (not in a function)
/usr/include/sys/socket.h:190: size of array `__ss_pad1' is too large
/usr/include/sys/socket.h:191: syntax error before `int64_t'
/usr/include/sys/socket.h:192: `u_char' undeclared here (not in a function)
/usr/include/sys/socket.h:192: `int64_t' undeclared here (not in a function)
/usr/include/sys/socket.h:192: `u_char' undeclared here (not in a function)
/usr/include/sys/socket.h:192: `int64_t' undeclared here (not in a function)
/usr/include/sys/socket.h:359: syntax error before `pid_t'
/usr/include/sys/socket.h:364: syntax error before `gid_t'
/usr/include/sys/socket.h:399: syntax error before `u_short'
/usr/include/sys/socket.h:407: syntax error before `caddr_t'
/usr/include/sys/socket.h:411: syntax error before `caddr_t'
In file included from smb-method.c:25:
/usr/include/sys/socket.h:444: syntax error before `recv'
/usr/include/sys/socket.h:444: syntax error before `size_t'
/usr/include/sys/socket.h:444: warning: data definition has no type or storage class
/usr/include/sys/socket.h:445: syntax error before `recvfrom'
/usr/include/sys/socket.h:445: syntax error before `size_t'
/usr/include/sys/socket.h:445: warning: data definition has no type or storage class
/usr/include/sys/socket.h:446: syntax error before `recvmsg'
/usr/include/sys/socket.h:446: warning: data definition has no type or storage class
/usr/include/sys/socket.h:447: syntax error before `send'
/usr/include/sys/socket.h:447: syntax error before `size_t'
/usr/include/sys/socket.h:447: warning: data definition has no type or storage class
/usr/include/sys/socket.h:448: syntax error before `sendto'
/usr/include/sys/socket.h:449: syntax error before `size_t'
/usr/include/sys/socket.h:449: warning: data definition has no type or storage class
/usr/include/sys/socket.h:450: syntax error before `sendmsg'
/usr/include/sys/socket.h:450: warning: data definition has no type or storage class
/usr/include/sys/socket.h:451: syntax error before `off_t'
In file included from smb-method.c:26:
/usr/include/netinet/in.h:233: syntax error before `in_addr_t'
/usr/include/netinet/in.h:285: syntax error before `u_char'
In file included from /usr/include/netinet/in.h:467,
                 from smb-method.c:26:
/usr/include/netinet6/in6.h:122: syntax error before `u_int8_t'
/usr/include/netinet6/in6.h:144: syntax error before `u_int8_t'
/usr/include/netinet6/in6.h:149: syntax error before `u_int32_t'
/usr/include/netinet6/in6.h:612: syntax error before `*'
/usr/include/netinet6/in6.h:614: syntax error before `*'
/usr/include/netinet6/in6.h:614: warning: data definition has no type or storage class
/usr/include/netinet6/in6.h:615: syntax error before `u_int8_t'
/usr/include/netinet6/in6.h:616: syntax error before `u_int8_t'
/usr/include/netinet6/in6.h:618: syntax error before `inet6_rthdr_space'
/usr/include/netinet6/in6.h:618: warning: data definition has no type or storage class
/usr/include/netinet6/in6.h:630: syntax error before `size_t'
/usr/include/netinet6/in6.h:631: syntax error before `size_t'
/usr/include/netinet6/in6.h:633: syntax error before `size_t'
/usr/include/netinet6/in6.h:634: syntax error before `size_t'
/usr/include/netinet6/in6.h:636: syntax error before `size_t'
/usr/include/netinet6/in6.h:638: syntax error before `size_t'
/usr/include/netinet6/in6.h:640: syntax error before `size_t'
/usr/include/netinet6/in6.h:641: syntax error before `inet6_rth_space'
/usr/include/netinet6/in6.h:641: warning: data definition has no type or storage class
--- end paste ---

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1025262407.272.78.camel>