This is the mail archive of the cygwin-patches@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Make ip.h and tcp.h work under -fnative-struct or -fms-bitfields


On Mon, Nov 11, 2002 at 04:55:25PM +0800, Wu Yongwei wrote:
>Hi,
>
>What's the status of this patch?
>
>----------
>ChangeLog:
>
>2002-10-28  Wu Yongwei <adah@netstd.com>
>
>    * ip.h (struct ip): Use u_char to indicate bitfields to make it
>    work with -fnative-struct/-fms-bitfields.
>    (struct ip_timestamp): Ditto.
>    * tcp.h (struct tcphdr): Ditto.
>----------
>
>Am I really going the wrong way (any examples)? Or should I submit a new 
>patch as Danny suggests?

Danny's suggestion is correct.  The rest of the header files which accomodate
this are probably using __attribute__((packed)) .  The argument that the header
works ok for you on MSVC is a non-issue for cygwin.

cgf


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]