--On Wednesday, October 27, 2004 17:04:35 -0400 John Wehle <[EMAIL PROTECTED]> wrote:

IP Filter bug report form.
--------------------------
IP Filter Version: 4.1.3
Operating System Version: Solaris 9 x86
Configuration: LKM

Description of problem:

While looking at another issue I noticed htonl being used
with tcp->th_seq and tcp->th_ack in a couple of places.
Most of the code seems to imply tcp->th_seq and tcp->th_ack
are network byte order which means htonl should never be
used with them.

How to repeat:

Since htonl and ntohl tend to do the same thing I'm not
sure that there is anything to repeat.  The enclosed patch
to ip_state.c is for the sake of code clarity.

ntohl and htonl do _not_ do the same thing! They are inverse functions. x = (htonl(ntohl(x)). This is not a cosmetic change.


--
Carson



Reply via email to