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

Side by Side Diff: net/tools/quic/quic_socket_utils.cc

Issue 1427143003: include what you use: errno.h and string.h in net/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month 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
OLDNEW
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/tools/quic/quic_socket_utils.h" 5 #include "net/tools/quic/quic_socket_utils.h"
6 6
7 #include <errno.h> 7 #include <errno.h>
8 #include <netinet/in.h> 8 #include <netinet/in.h>
9 #include <string.h>
9 #include <sys/socket.h> 10 #include <sys/socket.h>
10 #include <sys/uio.h> 11 #include <sys/uio.h>
11 #include <string> 12 #include <string>
12 13
13 #include "base/basictypes.h" 14 #include "base/basictypes.h"
14 #include "base/logging.h" 15 #include "base/logging.h"
15 #include "net/quic/quic_protocol.h" 16 #include "net/quic/quic_protocol.h"
16 17
17 #ifndef SO_RXQ_OVFL 18 #ifndef SO_RXQ_OVFL
18 #define SO_RXQ_OVFL 40 19 #define SO_RXQ_OVFL 40
(...skipping 194 matching lines...) Expand 10 before | Expand all | Expand 10 after
213 int rc = sendmsg(fd, &hdr, 0); 214 int rc = sendmsg(fd, &hdr, 0);
214 if (rc >= 0) { 215 if (rc >= 0) {
215 return WriteResult(WRITE_STATUS_OK, rc); 216 return WriteResult(WRITE_STATUS_OK, rc);
216 } 217 }
217 return WriteResult((errno == EAGAIN || errno == EWOULDBLOCK) ? 218 return WriteResult((errno == EAGAIN || errno == EWOULDBLOCK) ?
218 WRITE_STATUS_BLOCKED : WRITE_STATUS_ERROR, errno); 219 WRITE_STATUS_BLOCKED : WRITE_STATUS_ERROR, errno);
219 } 220 }
220 221
221 } // namespace tools 222 } // namespace tools
222 } // namespace net 223 } // namespace net
OLDNEW
« net/socket/tcp_socket_win.cc ('K') | « net/tools/flip_server/flip_in_mem_edsm_server.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698