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

Side by Side Diff: runtime/bin/socket_android.cc

Issue 18829003: - Use TCP_NODELAY when using the coverage tool. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 5 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 | « runtime/bin/dbg_connection.cc ('k') | runtime/bin/socket_linux.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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "platform/globals.h" 5 #include "platform/globals.h"
6 #if defined(TARGET_OS_ANDROID) 6 #if defined(TARGET_OS_ANDROID)
7 7
8 #include <errno.h> // NOLINT 8 #include <errno.h> // NOLINT
9 #include <stdio.h> // NOLINT 9 #include <stdio.h> // NOLINT
10 #include <stdlib.h> // NOLINT 10 #include <stdlib.h> // NOLINT
(...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after
353 353
354 354
355 bool Socket::SetBlocking(intptr_t fd) { 355 bool Socket::SetBlocking(intptr_t fd) {
356 return FDUtils::SetBlocking(fd); 356 return FDUtils::SetBlocking(fd);
357 } 357 }
358 358
359 359
360 bool Socket::SetNoDelay(intptr_t fd, bool enabled) { 360 bool Socket::SetNoDelay(intptr_t fd, bool enabled) {
361 int on = enabled ? 1 : 0; 361 int on = enabled ? 1 : 0;
362 return TEMP_FAILURE_RETRY(setsockopt(fd, 362 return TEMP_FAILURE_RETRY(setsockopt(fd,
363 SOL_TCP, 363 IPPROTO_TCP,
364 TCP_NODELAY, 364 TCP_NODELAY,
365 reinterpret_cast<char *>(&on), 365 reinterpret_cast<char *>(&on),
366 sizeof(on))) == 0; 366 sizeof(on))) == 0;
367 } 367 }
368 368
369 } // namespace bin 369 } // namespace bin
370 } // namespace dart 370 } // namespace dart
371 371
372 #endif // defined(TARGET_OS_ANDROID) 372 #endif // defined(TARGET_OS_ANDROID)
OLDNEW
« no previous file with comments | « runtime/bin/dbg_connection.cc ('k') | runtime/bin/socket_linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698