Skip to content

Commit

Permalink
Merge branch 'feature/non-standard-headers' of github.com:nxxm/xxhr i…
Browse files Browse the repository at this point in the history
…nto debug/use_openssl
  • Loading branch information
daminetreg committed Jun 8, 2021
2 parents 2c8756d + 50d8927 commit af9f116
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion xxhr/impl/session-beast.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,12 @@ namespace xxhr {
for (auto&& entry : header) {
auto& h = entry.first;
auto& v = entry.second;
req_.set(boost::beast::http::string_to_field(h), v);
auto field = boost::beast::http::string_to_field(h);
if (field == boost::beast::http::field::unknown) {
req_.insert(h, v);
} else {
req_.set(field, v);
}
}
}

Expand Down

0 comments on commit af9f116

Please sign in to comment.