> Arrgh.  Now it seems I might need to reverse my position.  I looked
> through some code fragments in UNIX Network Programming (Volume 1,
> Second Edition, pp. 362-365), and there's some precedent for needing
> <sys/param.h> with the CMSG*() macros.
> 
> On the other hand, RFC 2292 and draft-ietf-ipngwg-rfc2292bis (the
> references I was originally working from) don't mention this requirement
> at all; they just say that CMSG*() are defined with <sys/socket.h>.  I'm
> slightly confused by now.
> 
> I'm going to send off a note to the authors of 
> draft-ietf-ipngwg-rfc229bis asking for some clarification.  In the 
> meantime, maybe we should hold off on doing any changes.
> 
> Bruce.

There seems to be no message from bmah related to this, so I
now add a follow-up here.

The authors' reply is that,

>The X/Open (as well as POSIX I think) man pages for sendmsg()
>only list socket.h as an include file.
>The old BSD man pages list both param.h and socket.h.

And, from `man sendmsg` on FreeBSD, only,

>SYNOPSIS
>     #include <sys/types.h>
>     #include <sys/socket.h>

are required.

So I think machine/param.h should be included from
sys/socket.h for more portability.

It is my fault and sorry for bmah and possibly other ports
maintainers.
I'll also create an ERRATA entry for this.

And I'll fix it on current and stable tree.
I checked the following patch on 5.0 and make world was OK.
I'll commit this, so if param.h inclusion related problem
happens for any of ports, please let me know.

Thanks,
Yoshinobu Inoue

===================================================================
RCS file: /home/ncvs/src/sys/sys/socket.h,v
retrieving revision 1.39
diff -u -r1.39 socket.h
--- socket.h    2000/03/11 19:51:04     1.39
+++ socket.h    2000/03/25 10:13:45
@@ -37,6 +37,9 @@
 #ifndef _SYS_SOCKET_H_
 #define        _SYS_SOCKET_H_
 
+/* for ALIGN() */
+#include <machine/param.h>
+
 /*
  * Definitions related to sockets: types, address families, options.
  */


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message

Reply via email to