Bug 226 - tcp-impl doesn't invoke NotifySend () even though app is blocked
tcp-impl doesn't invoke NotifySend () even though app is blocked
Status: RESOLVED FIXED
Product: ns-3
Classification: Unclassified
Component: internet
pre-release
All All
: P1 major
Assigned To: ns-bugs
:
Depends on:
Blocks: 227
  Show dependency treegraph
 
Reported: 2008-06-18 15:06 UTC by Florian Westphal
Modified: 2008-06-19 00:27 UTC (History)
0 users

See Also:


Attachments
Suggested Fix: set m_wouldBlock to false before invoking the callback. (1.37 KB, patch)
2008-06-18 15:07 UTC, Florian Westphal
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Florian Westphal 2008-06-18 15:06:26 UTC
tcp-impl doesn't invoke NotifySend () under the following condition:

1. App has blocked, m_wouldBlock is true, new tx space becomes available
2. tcp-impl invokes NotifySend () callback
   App callback writes data, ok
   App callback writes data, blocks again
3. tcp-impl sets m_wouldBlock to false after callback returns

After this happens, NotifySend () is no longer called, even though
the app is blocked.
Comment 1 Florian Westphal 2008-06-18 15:07:58 UTC
Created attachment 172 [details]
Suggested Fix: set m_wouldBlock to false before invoking the callback.
Comment 2 Rajib Bhattacharjea 2008-06-18 15:42:52 UTC
This looks right, thanks Florian.  This looks ready to push to me.