[Top][All Lists]

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

Re: [lwip-users] socket write hangs, in LwIP 1.4.? (ppp-new branch but n

From: Mark Lakata
Subject: Re: [lwip-users] socket write hangs, in LwIP 1.4.? (ppp-new branch but not ppp related)
Date: Thu, 20 Dec 2012 11:55:19 -0800
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/17.0 Thunderbird/17.0

On 12/20/2012 12:25 AM, address@hidden wrote:
Mark Lakata wrote:
I think I've gotten closer to the problem. It seems that the size of the segments that are queued up to be sent by tcp_output are larger than the 'wnd' size (which is pcb->snd_wnd in this case), and thus they don't get sent. I'm not sure how this could have happened.

Specifically, this while() loop never gets entered (line 969 in tcp_out.c) in tcp_output() 

(seg is non NULL)

  while (seg != NULL &&
         ntohl(seg->tcphdr->seqno) - pcb->lastack + seg->len <= wnd) {

because seg->len is bigger than wnd.

Which version of lwIP are you using? (i.e. what does '?' stand for?) I'm asking because from 1.4.0 to 1.4.1, there have been 2 or 3 bugs fixed in this area, which should ensure that all segments we create fit into the window (unless the remote side does not send window updates according to the TCP spec).

I'm using the head of the ppp-new branch. I'm going to plead almost complete ignorance of how git works (haven't gotten around to learning it) and learned just enough to download the ppp-new branch. Has the ppp-new branch being pushed back into the main line? Is there an easy way of merging the two branches together? Does that sentence even make sense?  I need the ppp-new branch, since I had trouble with the released ppp code, which I think was 1.4.0.

If 1.4.1 does not fix this, what is your MSS size, what are the connection's TX/RX window sizes and what OS or IP stack is your peer running?

I'm not sure how to get the size of the "connections's TX/RX window sizes". Here is a snippet from the lwipopts.h.  The peer is Windows 7 Google Chrome.

#define LWIP_TCP                1
#define TCP_TTL                 255
#define TCP_QUEUE_OOSEQ         0
#define TCP_MSS                 (1500 - 40)
#define TCP_SND_BUF             (2*TCP_MSS)
#define TCP_WND                 (2*TCP_MSS)


lwip-users mailing list

reply via email to

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