Bug 417

Summary: stack explosion when sending to loopback device
Product: ns-3 Reporter: Mathieu Lacage <mathieu.lacage>
Component: internetAssignee: Rajib Bhattacharjea <raj.b>
Status: RESOLVED FIXED    
Severity: normal CC: craigdo, tommaso.pecorella
Priority: P1    
Version: pre-release   
Hardware: All   
OS: All   
Bug Depends on:    
Bug Blocks: 2211    
Attachments: avoid infinite stack recursion.

Description Mathieu Lacage 2008-11-24 02:45:39 EST
If you use the tcp or udp stacks, and attempt to send and receive packets from the loopback device, you risk getting into a stack explosion. The attached patch fixes this in a very minimally intrusive way.

(testcase exhibiting the bug and exercising the fix is in the ns-3-simu tree)
Comment 1 Mathieu Lacage 2008-11-24 02:46:37 EST
Created attachment 313 [details]
avoid infinite stack recursion.
Comment 2 Mathieu Lacage 2008-12-10 02:37:02 EST
there is not much I can do here. I am waiting for an ACK from the relevant maintainer, and that means raj. Reassigning to raj: if it's ok with you, please apply.
Comment 3 Rajib Bhattacharjea 2008-12-11 16:55:37 EST
this causes regressions (it seems?)

more on the way.
Comment 4 Rajib Bhattacharjea 2008-12-11 17:11:43 EST
Given that this patch changes the order of execution of functions, it should probably change time stamps for events as well (which it appears to do).  I think it is good.
Comment 5 Rajib Bhattacharjea 2008-12-13 23:30:16 EST
Changeset
4022:142c13a3975f
Comment 6 Tommaso Pecorella 2015-11-08 17:31:35 EST
According to Massif's output, this bug is not anymore relevant thanks to the changes in LoopbackNetDevice.