Bug 54

Summary: Buffer data corruption errors
Product: ns-3 Reporter: Gustavo J. A. M. Carneiro <gjcarneiro>
Component: coreAssignee: ns-bugs <ns-bugs>
Status: RESOLVED FIXED    
Severity: blocker    
Priority: P1    
Version: pre-release   
Hardware: PC   
OS: Linux   
Attachments: Adds a utils/buffer-stress-testing program

Description Gustavo J. A. M. Carneiro 2007-07-17 09:51:43 EDT
I have made a "buffer stress testing" program which demonstrates that there exists at least one bug inside Buffer occasionally causing data corruption when headers are added and removed.  This bug is affecting my OLSR codel, but I am not sure I am able to fix it in useful time :-(
Comment 1 Gustavo J. A. M. Carneiro 2007-07-17 09:52:37 EDT
Created attachment 31 [details]
Adds a utils/buffer-stress-testing program
Comment 2 Gustavo J. A. M. Carneiro 2007-07-17 10:09:18 EDT
A sample of what error is given:

Testing with a packet of size 83339
Chunk size 4411
Chunk size 77656
Chunk size 838
Chunk size 144
Chunk size 231
Chunk size 51
Chunk size 7
Chunk size 1
Comparing resulting buffer with original...
assert failed. file=../utils/buffer-stress-testing.cc, line=69, cond="memcmp (outputBuffer.PeekData (), inputBuffer.PeekData (), actualSize) == 0"
Segmentation fault (core dumped)

This means memory comparison fails, which means data corruption happened somewhere.
Comment 3 Gustavo J. A. M. Carneiro 2007-07-19 07:49:33 EDT
Fixed in ns-3-dev