| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "net/tools/balsa/balsa_headers.h" | 5 #include "net/tools/balsa/balsa_headers.h" |
| 6 | 6 |
| 7 #include <stdio.h> | 7 #include <stdio.h> |
| 8 #include <algorithm> | 8 #include <algorithm> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <utility> | 10 #include <utility> |
| 11 #include <vector> | 11 #include <vector> |
| 12 | 12 |
| 13 #include "base/containers/hash_tables.h" | 13 #include "base/containers/hash_tables.h" |
| 14 #include "base/logging.h" | 14 #include "base/logging.h" |
| 15 #include "base/port.h" | |
| 16 #include "base/strings/string_piece.h" | 15 #include "base/strings/string_piece.h" |
| 17 #include "base/strings/stringprintf.h" | 16 #include "base/strings/stringprintf.h" |
| 18 #include "net/tools/balsa/balsa_enums.h" | 17 #include "net/tools/balsa/balsa_enums.h" |
| 19 #include "net/tools/balsa/buffer_interface.h" | 18 #include "net/tools/balsa/buffer_interface.h" |
| 20 #include "net/tools/balsa/simple_buffer.h" | 19 #include "net/tools/balsa/simple_buffer.h" |
| 21 #include "third_party/tcmalloc/chromium/src/base/googleinit.h" | 20 #include "third_party/tcmalloc/chromium/src/base/googleinit.h" |
| 22 | 21 |
| 23 #if defined(COMPILER_MSVC) | 22 #if defined(COMPILER_MSVC) |
| 24 #include <string.h> | 23 #include <string.h> |
| 25 #define snprintf _snprintf | 24 #define snprintf _snprintf |
| (...skipping 944 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 970 | 969 |
| 971 void BalsaHeaders::SetResponseReasonPhrase(const base::StringPiece& reason) { | 970 void BalsaHeaders::SetResponseReasonPhrase(const base::StringPiece& reason) { |
| 972 // Note: There is no difference between request_version() and | 971 // Note: There is no difference between request_version() and |
| 973 // response_reason_phrase(). Thus, a function to set one is equivalent to a | 972 // response_reason_phrase(). Thus, a function to set one is equivalent to a |
| 974 // function to set the other. We maintain two functions for this as it is | 973 // function to set the other. We maintain two functions for this as it is |
| 975 // much more descriptive, and makes code more understandable. | 974 // much more descriptive, and makes code more understandable. |
| 976 SetRequestVersion(reason); | 975 SetRequestVersion(reason); |
| 977 } | 976 } |
| 978 | 977 |
| 979 } // namespace net | 978 } // namespace net |
| OLD | NEW |