If memory serves me right, Yoshinobu Inoue wrote:
> > > I feel requesting inclusion of machine/param.h for any apps
> > > which use socket is better. But if there are any other smarter
> > > solution, please let me know and I'll appreciate it much.
> >
> > <machine/param.h> should never be included by applications since
> > it is an implementation detail.
> >
> > Specify including <sys/param.h> in apps which use the CMSG*() macros.
> > <sys/socket.h> doesn't depend on <*/param.h> unless these macros are used.
> > Since these macros are undocumented, applications that use them should
> > expect problems :-).
> >
> > Bruce
>
> After reading bmah's message, now I am inclined to including
> machine/param.h from sys/socket.h for maximum portability, if
> there is no spec for it, and if all other platforms doing it.
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.
PGP signature