lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-users] Re: [lwip] tcp_input() help


From: Kieran Mansley
Subject: [lwip-users] Re: [lwip] tcp_input() help
Date: Thu, 09 Jan 2003 00:43:55 -0000

On Wed, 18 Dec 2002, ajay kapoor wrote:
> I am using the vc++ version of lwip stack. There seems to be problem with the 
> below function in tcp_input().
>
> //   pbuf_header(p, -(IPH_HL(iphdr) * 4/sizeof(s8_t)));
>
> when i replace the - sign with * -1 it seems to work fine.
>
> pbuf_header(p, (IPH_HL(iphdr) * 4/sizeof(u8_t))* -1);
>
> is it ok to do that.

Mathematically, yes, it will give the same answer.  It sounds like your
compiler is broken though as it should have no problem compiling that
code.

> also the tcp checksum function inet_chksum_pseudo() is failing.

In what way.  ie.  Failing to compile?  Failing to give the correct
answer?  Failing in the sense of rejecting packets on reception?

Kieran

[This message was sent through the lwip discussion list.]




reply via email to

[Prev in Thread] Current Thread [Next in Thread]