From 384cbd411de4247f1cd2e4b364d855704c91eb8c Mon Sep 17 00:00:00 2001 From: Bryan Roe Date: Tue, 21 Jan 2020 13:27:45 -0800 Subject: [PATCH] Fixed edge case bug, where HTTP body fragment could get written to stream without acknowledging it, at the start of the response, which could result in the bodystream having a single duplicate fragment. --- microscript/ILibDuktape_HttpStream.c | 1 + 1 file changed, 1 insertion(+) diff --git a/microscript/ILibDuktape_HttpStream.c b/microscript/ILibDuktape_HttpStream.c index 415892c..d7b6eb2 100644 --- a/microscript/ILibDuktape_HttpStream.c +++ b/microscript/ILibDuktape_HttpStream.c @@ -3075,6 +3075,7 @@ void ILibDuktape_HttpStream_OnReceive(ILibWebClient_StateObject WebStateObject, if (bodyBuffer != NULL && endPointer > 0) { ILibDuktape_readableStream_WriteData(data->bodyStream, bodyBuffer + *beginPointer, endPointer); + *beginPointer += endPointer; } break; }