Skip to content

Commit

Permalink
roll back the while loop in _parseForm
Browse files Browse the repository at this point in the history
  • Loading branch information
me-no-dev committed Jul 25, 2018
1 parent 17065df commit 7d2560c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions libraries/WebServer/src/Parsing.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -477,14 +477,14 @@ bool WebServer::_parseForm(WiFiClient& client, String boundary, uint32_t len){
if(_currentHandler && _currentHandler->canUpload(_currentUri))
_currentHandler->upload(*this, _currentUri, *_currentUpload);
_currentUpload->status = UPLOAD_FILE_WRITE;
int argByte;
int argByte = _uploadReadByte(client);
readfile:

do{
argByte = _uploadReadByte(client);
while(argByte != 0x0D){
if(argByte < 0) return _parseFormUploadAborted();
_uploadWriteByte(argByte);
}while(argByte != 0x0D);
argByte = _uploadReadByte(client);
}

argByte = _uploadReadByte(client);
if(argByte < 0) return _parseFormUploadAborted();
Expand Down

0 comments on commit 7d2560c

Please sign in to comment.