Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(208)

Side by Side Diff: net/base/big_endian.h

Issue 14223008: net: Update the include paths of base/string_piece.h to its new location. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « net/android/keystore.h ('k') | net/base/big_endian.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #ifndef NET_BASE_BIG_ENDIAN_H_ 5 #ifndef NET_BASE_BIG_ENDIAN_H_
6 #define NET_BASE_BIG_ENDIAN_H_ 6 #define NET_BASE_BIG_ENDIAN_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/string_piece.h" 9 #include "base/strings/string_piece.h"
10 #include "net/base/net_export.h" 10 #include "net/base/net_export.h"
11 11
12 namespace net { 12 namespace net {
13 13
14 // Read an integer (signed or unsigned) from |buf| in Big Endian order. 14 // Read an integer (signed or unsigned) from |buf| in Big Endian order.
15 // Note: this loop is unrolled with -O1 and above. 15 // Note: this loop is unrolled with -O1 and above.
16 // NOTE(szym): glibc dns-canon.c and SpdyFrameBuilder use 16 // NOTE(szym): glibc dns-canon.c and SpdyFrameBuilder use
17 // ntohs(*(uint16_t*)ptr) which is potentially unaligned. 17 // ntohs(*(uint16_t*)ptr) which is potentially unaligned.
18 // This would cause SIGBUS on ARMv5 or earlier and ARMv6-M. 18 // This would cause SIGBUS on ARMv5 or earlier and ARMv6-M.
19 template<typename T> 19 template<typename T>
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 bool Write(T v); 94 bool Write(T v);
95 95
96 char* ptr_; 96 char* ptr_;
97 char* end_; 97 char* end_;
98 }; 98 };
99 99
100 } // namespace net 100 } // namespace net
101 101
102 #endif // NET_BASE_BIG_ENDIAN_H_ 102 #endif // NET_BASE_BIG_ENDIAN_H_
103 103
OLDNEW
« no previous file with comments | « net/android/keystore.h ('k') | net/base/big_endian.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698