| Index: net/spdy/hpack_encoder.cc
|
| diff --git a/net/spdy/hpack_encoder.cc b/net/spdy/hpack_encoder.cc
|
| index 0ba353782c56b4f369e279bc848f4c93ee532d7b..bc56efefbc883b040054e7f6416f4b24f97899dc 100644
|
| --- a/net/spdy/hpack_encoder.cc
|
| +++ b/net/spdy/hpack_encoder.cc
|
| @@ -64,10 +64,7 @@ bool HpackEncoder::EncodeHeaderSet(const std::map<string, string>& header_set,
|
| }
|
| }
|
|
|
| - // Encode regular headers that are already in the header table first,
|
| - // save the rest into another vector. This way we avoid evicting an entry
|
| - // from the header table before it can be used.
|
| - Representations literal_headers;
|
| + // Encode regular headers.
|
| for (Representations::const_iterator it = regular_headers.begin();
|
| it != regular_headers.end(); ++it) {
|
| const HpackEntry* entry =
|
| @@ -75,17 +72,10 @@ bool HpackEncoder::EncodeHeaderSet(const std::map<string, string>& header_set,
|
| if (entry != NULL) {
|
| EmitIndex(entry);
|
| } else {
|
| - literal_headers.push_back(*it);
|
| + EmitIndexedLiteral(*it);
|
| }
|
| }
|
|
|
| - // Encode the remaining header fields, while inserting them in the header
|
| - // table.
|
| - for (Representations::const_iterator it = literal_headers.begin();
|
| - it != literal_headers.end(); ++it) {
|
| - EmitIndexedLiteral(*it);
|
| - }
|
| -
|
| output_stream_.TakeString(output);
|
| return true;
|
| }
|
|
|