forked from boostorg/beast
Fix handling empty HTTP headers in parser_v1.hpp
This patch rectifies flush() of beast::http::parser_v1 to properly handle the case when an HTTP header has empty value. Without the fix an empty-valued HTTP header is being concatenated with the header directly following it. This situation can be replicated using eg. curl: curl <url> -H "X-First;" -H "X-Second: bla" What Beast's client would see is a single header named as "X-FirstX-Second".
This commit is contained in:
committed by
Vinnie Falco
parent
843d7a5a9c
commit
bc665ee1ec
@@ -263,7 +263,7 @@ public:
|
||||
}
|
||||
catch(system_error const& se)
|
||||
{
|
||||
BEAST_EXPECT(se.code() == ev);
|
||||
BEAST_EXPECTS(se.code() == ev, se.what());
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user