mirror of
https://github.com/matrix-construct/construct
synced 2024-11-29 10:12:39 +01:00
ircd::http: Parse content_type convenience reference in response::head.
This commit is contained in:
parent
8f9a4aad7d
commit
64a77e280d
2 changed files with 4 additions and 0 deletions
|
@ -343,6 +343,7 @@ struct ircd::http::response::head
|
|||
:line::response
|
||||
{
|
||||
size_t content_length {0};
|
||||
string_view content_type;
|
||||
string_view transfer_encoding;
|
||||
string_view server;
|
||||
|
||||
|
|
|
@ -450,6 +450,9 @@ ircd::http::response::head::head(parse::capstan &pc,
|
|||
if(iequals(h.first, "content-length"s))
|
||||
this->content_length = parser.content_length(h.second);
|
||||
|
||||
else if(iequals(h.first, "content-type"s))
|
||||
this->content_type = h.second;
|
||||
|
||||
else if(iequals(h.first, "transfer-encoding"s))
|
||||
this->transfer_encoding = h.second;
|
||||
|
||||
|
|
Loading…
Reference in a new issue