ufairiya / mongoose

Automatically exported from code.google.com/p/mongoose
MIT License
0 stars 0 forks source link

mg_read buffering defective #188

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
:calling mg_read in POST handler multiple times with len = 64

What is the expected output? What do you see instead?
:the second call to mg_read will return the same (beginning) of the POST data 
buffer as the first call

What version of the product are you using? On what operating system?
:mongoose 2-11 with Windows Vista

Please provide any additional information below.
Fixed it by changing line 1343 to
      memcpy(buf, buffered + conn->consumed_content, buffered_len);

Original issue reported on code.google.com by ruediger...@googlemail.com on 13 Oct 2010 at 11:15

GoogleCodeExporter commented 9 years ago
I didn't notice this issue was already reported an duplicated it as Issue 200.

I have a fix in the arnoutvandecappelle-multiplereads clone.

Original comment by arnout.v...@gmail.com on 2 Nov 2010 at 1:56

GoogleCodeExporter commented 9 years ago
Thank you. Will take a look at the fix asap.

Original comment by valenok on 2 Nov 2010 at 4:12

GoogleCodeExporter commented 9 years ago
Issue 200 has been merged into this issue.

Original comment by valenok on 2 Nov 2010 at 4:12

GoogleCodeExporter commented 9 years ago
Pushed Arnout's fixes. Thank you.

Original comment by valenok on 3 Nov 2010 at 7:32