OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/quic/quic_utils.h" | 5 #include "net/quic/quic_utils.h" |
6 | 6 |
7 #include <ctype.h> | 7 #include <ctype.h> |
8 | 8 |
9 #include <algorithm> | 9 #include <algorithm> |
10 | 10 |
11 #include "base/basictypes.h" | 11 #include "base/basictypes.h" |
12 #include "base/logging.h" | 12 #include "base/logging.h" |
13 #include "base/port.h" | 13 #include "base/port.h" |
14 #include "base/strings/stringprintf.h" | 14 #include "base/strings/stringprintf.h" |
15 #include "base/strings/string_number_conversions.h" | 15 #include "base/strings/string_number_conversions.h" |
16 #include "net/spdy/write_blocked_list.h" | 16 #include "net/quic/quic_write_blocked_list.h" |
17 | 17 |
18 using base::StringPiece; | 18 using base::StringPiece; |
19 using std::string; | 19 using std::string; |
20 | 20 |
21 namespace net { | 21 namespace net { |
22 | 22 |
23 // static | 23 // static |
24 uint64 QuicUtils::FNV1a_64_Hash(const char* data, int len) { | 24 uint64 QuicUtils::FNV1a_64_Hash(const char* data, int len) { |
25 static const uint64 kOffset = GG_UINT64_C(14695981039346656037); | 25 static const uint64 kOffset = GG_UINT64_C(14695981039346656037); |
26 static const uint64 kPrime = GG_UINT64_C(1099511628211); | 26 static const uint64 kPrime = GG_UINT64_C(1099511628211); |
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
279 bytes_remaining -= line_bytes; | 279 bytes_remaining -= line_bytes; |
280 offset += line_bytes; | 280 offset += line_bytes; |
281 p += line_bytes; | 281 p += line_bytes; |
282 s += '\n'; | 282 s += '\n'; |
283 } | 283 } |
284 return s; | 284 return s; |
285 } | 285 } |
286 | 286 |
287 // static | 287 // static |
288 QuicPriority QuicUtils::LowestPriority() { | 288 QuicPriority QuicUtils::LowestPriority() { |
289 return static_cast<QuicPriority>(kLowestPriority); | 289 return QuicWriteBlockedList::kLowestPriority; |
290 } | 290 } |
291 | 291 |
292 // static | 292 // static |
293 QuicPriority QuicUtils::HighestPriority() { | 293 QuicPriority QuicUtils::HighestPriority() { |
294 return static_cast<QuicPriority>(kHighestPriority); | 294 return QuicWriteBlockedList::kHighestPriority; |
295 } | 295 } |
296 | 296 |
297 } // namespace net | 297 } // namespace net |
OLD | NEW |