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

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

Issue 465133002: - Fix vm/thread.h and bin/thread.h confusion. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 4 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 | « no previous file | runtime/bin/socket_win.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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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_LINUX) 6 #if defined(TARGET_OS_LINUX)
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
11 #include <string.h> // NOLINT 11 #include <string.h> // NOLINT
12 #include <sys/stat.h> // NOLINT 12 #include <sys/stat.h> // NOLINT
13 #include <unistd.h> // NOLINT 13 #include <unistd.h> // NOLINT
14 #include <net/if.h> // NOLINT 14 #include <net/if.h> // NOLINT
15 #include <netinet/tcp.h> // NOLINT 15 #include <netinet/tcp.h> // NOLINT
16 #include <ifaddrs.h> // NOLINT 16 #include <ifaddrs.h> // NOLINT
17 17
18 #include "bin/fdutils.h" 18 #include "bin/fdutils.h"
19 #include "bin/file.h" 19 #include "bin/file.h"
20 #include "bin/socket.h" 20 #include "bin/socket.h"
21 #include "bin/thread.h"
21 #include "platform/signal_blocker.h" 22 #include "platform/signal_blocker.h"
22 #include "vm/thread.h"
23 23
24 24
25 namespace dart { 25 namespace dart {
26 namespace bin { 26 namespace bin {
27 27
28 SocketAddress::SocketAddress(struct sockaddr* sa) { 28 SocketAddress::SocketAddress(struct sockaddr* sa) {
29 ASSERT(INET6_ADDRSTRLEN >= INET_ADDRSTRLEN); 29 ASSERT(INET6_ADDRSTRLEN >= INET_ADDRSTRLEN);
30 if (!Socket::FormatNumericAddress( 30 if (!Socket::FormatNumericAddress(
31 reinterpret_cast<RawAddr*>(sa), as_string_, INET6_ADDRSTRLEN)) { 31 reinterpret_cast<RawAddr*>(sa), as_string_, INET6_ADDRSTRLEN)) {
32 as_string_[0] = 0; 32 as_string_[0] = 0;
(...skipping 519 matching lines...) Expand 10 before | Expand all | Expand 10 after
552 mreq.gr_interface = interfaceIndex; 552 mreq.gr_interface = interfaceIndex;
553 memmove(&mreq.gr_group, &addr->ss, SocketAddress::GetAddrLength(addr)); 553 memmove(&mreq.gr_group, &addr->ss, SocketAddress::GetAddrLength(addr));
554 return NO_RETRY_EXPECTED( 554 return NO_RETRY_EXPECTED(
555 setsockopt(fd, proto, MCAST_LEAVE_GROUP, &mreq, sizeof(mreq))) == 0; 555 setsockopt(fd, proto, MCAST_LEAVE_GROUP, &mreq, sizeof(mreq))) == 0;
556 } 556 }
557 557
558 } // namespace bin 558 } // namespace bin
559 } // namespace dart 559 } // namespace dart
560 560
561 #endif // defined(TARGET_OS_LINUX) 561 #endif // defined(TARGET_OS_LINUX)
OLDNEW
« no previous file with comments | « no previous file | runtime/bin/socket_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698