We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 41bd7af commit b72cf2cCopy full SHA for b72cf2c
libraries/ESP8266WebServer/src/Parsing.cpp
@@ -153,7 +153,13 @@ bool ESP8266WebServer::_parseRequest(WiFiClient& client) {
153
plainLen += newLen;
154
plainBuf[plainLen] = '\0';
155
} while (plainLen < contentLength);
156
+ /* if data loss, exit */
157
if (plainBuf == nullptr) return false;
158
+ if (plainLen < contentLength)
159
+ {
160
+ free(plainBuf);
161
+ return false;
162
+ }
163
#ifdef DEBUG_ESP_HTTP_SERVER
164
DEBUG_OUTPUT.print("Plain: ");
165
DEBUG_OUTPUT.println(plainBuf);
0 commit comments