forked from boostorg/beast
Fix chunk delimiter parsing
This commit is contained in:
@@ -10,6 +10,7 @@ Version 50
|
||||
* Fields concept work
|
||||
* Body documentation work
|
||||
* Add missing handler_alloc nested types
|
||||
* Fix chunk delimiter parsing
|
||||
|
||||
API Changes:
|
||||
|
||||
|
@@ -512,11 +512,16 @@ parse_chunk_header(char const*& p,
|
||||
// be parsed in one call instead of two.
|
||||
if(f_ & flagExpectCRLF)
|
||||
{
|
||||
if(n < 2 || ! parse_crlf(p))
|
||||
if(n < 2)
|
||||
{
|
||||
ec = error::need_more;
|
||||
return;
|
||||
}
|
||||
if(! parse_crlf(p))
|
||||
{
|
||||
ec = error::bad_chunk;
|
||||
return;
|
||||
}
|
||||
f_ &= ~flagExpectCRLF;
|
||||
pbegin += 2;
|
||||
n -= 2;
|
||||
|
Reference in New Issue
Block a user