nghttp: Sort request header fields using http2::name_less
This commit is contained in:
parent
05f982dcfb
commit
76b3ba2832
|
@ -1043,11 +1043,7 @@ int submit_request
|
||||||
build_headers.emplace_back(kv.first, kv.second, no_index);
|
build_headers.emplace_back(kv.first, kv.second, no_index);
|
||||||
}
|
}
|
||||||
std::stable_sort(std::begin(build_headers), std::end(build_headers),
|
std::stable_sort(std::begin(build_headers), std::end(build_headers),
|
||||||
[](const Headers::value_type& lhs,
|
http2::name_less);
|
||||||
const Headers::value_type& rhs)
|
|
||||||
{
|
|
||||||
return lhs.name < rhs.name;
|
|
||||||
});
|
|
||||||
|
|
||||||
auto nva = std::vector<nghttp2_nv>();
|
auto nva = std::vector<nghttp2_nv>();
|
||||||
nva.reserve(build_headers.size());
|
nva.reserve(build_headers.size());
|
||||||
|
|
Loading…
Reference in New Issue