Commit Graph

78 Commits

Author SHA1 Message Date
iposva@google.com 2229450865 - Use TCP_NODELAY when using the coverage tool and ddbg.
- Use IPPROTO_TCP instead of SOL_TCP for increased portability.

R=asiva@google.com, hausner@google.com

Review URL: https://codereview.chromium.org//18829003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24865 260f80e4-7a28-3924-810f-c04153c831b5
2013-07-09 21:14:31 +00:00
ajohnsen@google.com 6005ff6a18 Fix comment from earlier commit.
BUG=
R=iposva@google.com

Review URL: https://codereview.chromium.org//18087003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24526 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-27 16:45:40 +00:00
whesse@google.com 6aa0fafa00 Fix runtime build for Android
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//17860002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24510 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-27 08:31:17 +00:00
iposva@google.com 2d2f1bf4ea - Use VOID_TEMP_FAILURE_RETRY where needed
Review URL: https://codereview.chromium.org//17840009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24505 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-27 01:14:12 +00:00
ajohnsen@google.com 7aa0222b5b Avoid picking port 65535 for ServerSockets, when any is requested.
Some browsers block requests to 65535.

BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//17842003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24471 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-26 15:12:56 +00:00
ajohnsen@google.com 3ad9779be6 Add reverse dns lookup as a method on InternetAddress.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//17640008

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24393 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-25 11:27:48 +00:00
ajohnsen@google.com 63e62f6806 Update mac and android Socket::LookupAddress.
BUG=

Review URL: https://codereview.chromium.org//17341008

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24269 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-21 08:13:42 +00:00
ajohnsen@google.com 4624420914 Add NetworkAdaptor to dart:io.
NetworkAdaptor contains a static method, list, that will query the
underlaying system for active network adaptors.

BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//16514010

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24267 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-21 07:58:48 +00:00
johnmccutchan@google.com 9d264aaee5 Add support for loading scripts from http
R=iposva@google.com

Review URL: https://codereview.chromium.org//15966002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23351 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-29 14:34:15 +00:00
whesse@google.com a76b78a26e dart:io | Fix a few bugs in the Android port of dart:io.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//15894004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23260 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-28 12:58:30 +00:00
ajohnsen@google.com 6a78c0c0b8 Add v6Only named argument to ServerSocket and etc.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14766003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22309 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-02 11:23:40 +00:00
smok@google.com ebbc2020a2 Put everything in runtime/bin into '::dart::bin' namespace.
Review URL: https://codereview.chromium.org//14341015

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22032 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-25 14:22:30 +00:00
sgjesse@google.com d27309942c Fix broken Mac OS socket code
The order of the fields in the sockaddr structures on Mac OS was different and we where relying on the Linux/Windows order of fields. This should now be platform independent.

TBR=ajohnsen@google.com
BUG=

Review URL: https://codereview.chromium.org//14139032

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21940 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-24 11:51:56 +00:00
ajohnsen@google.com 55963a1a6d Add new InternetAddress class with a static lookup function (including IPv6
results).

Reapply of https://codereview.chromium.org/13880029/ with fixes.

BUG=

Review URL: https://codereview.chromium.org//14469002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21934 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-24 09:26:58 +00:00
ajohnsen@google.com 60946b53fc Revert "Add new InternetAddress class with a static lookup function (including IPv6 results)."
Revert "Attempt to fix strict align issue."
Revert "Trying another fix."

BUG=

Review URL: https://codereview.chromium.org//14036017

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21928 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-24 08:10:00 +00:00
ajohnsen@google.com 20d1f5ddda Add new InternetAddress class with a static lookup function (including IPv6 results).
Reapply of https://codereview.chromium.org/14083007/ with fixes.

BUG=

Review URL: https://codereview.chromium.org//13880029

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21923 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-24 07:12:05 +00:00
sgjesse@google.com afcb3ce69e Revert "Add new InternetAddress class with a static lookup function (including IPv6 results)"
TBR=ajohnsen@google.com

Review URL: https://codereview.chromium.org//14081024

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21865 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-23 10:07:03 +00:00
ajohnsen@google.com b33d142414 Add new InternetAddress class with a static lookup function (including IPv6 results).
Socket.connect/ServerSocket.bind now accepts IPv6 host names. If a new ServerSocket is connected to an IPv6 interface, it will (if possible) support incoming IPv4 connections as well.

BUG=

Review URL: https://codereview.chromium.org//14083007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21862 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-23 09:36:18 +00:00
ajohnsen@google.com fb53f40e65 Add setOption method on Socket/RawSocket.
This will allow the user to enable TCP_NODELAY on the native sockets.

BUG=

Review URL: https://codereview.chromium.org//12614014

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@20014 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-14 12:46:54 +00:00
tball@google.com ca8b23183b Added Socket::SetBlocking() and Socket::SetNonBlocking().
Review URL: https://codereview.chromium.org//12380032

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@19334 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-01 18:33:17 +00:00
iposva@google.com 9046a44a37 Prepare for removal of source_filter.gypi:
- Guard OS-dependent source files with #if TARGET_OS_* in a similar
  fashion to the architecture dependent sources.
Review URL: https://codereview.chromium.org//12282051

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@18786 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-20 21:17:38 +00:00
tball@google.com 898ec7731f Added Socket::Close() function.
Review URL: https://codereview.chromium.org//12209047

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@18199 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-07 00:44:55 +00:00
gram@google.com 3601944836 Revised CL for customisable logging (replacing printfs).
Review URL: https://codereview.chromium.org//11312242

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15096 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-19 17:38:15 +00:00
kustermann@google.com 6d1cda397c Added FD_CLOEXEC flag to client/server socket file descriptors
Without the FD_CLOEXEC, all subprocesses will inherit the open socket
file descriptors of the current process due to the default behavior
of fork()+exec().

Review URL: https://codereview.chromium.org//11416006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14952 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-15 11:27:33 +00:00
jackpal@google.com 5ef2b814bd Don't use TEMP_FAILURE_RETRY macro with inet_addr
inet_addr is not a syscall, therefore it should not be used with the
TEMP_FAILURE_RETRY macro.

This fixes a warning in the Android build.

Review URL: https://codereview.chromium.org//10907248

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12447 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-17 18:48:33 +00:00
jackpal@google.com e71572cebc Use casts to work around bug in Android TEMP_FAILURE_RETRY macro
See http://code.google.com/p/android/issues/detail?id=37426
"unistd.h TEMP_FAILURE_RETRY generates warning when used with syscall
 that returns unsigned int".

The Android version of this macro will generate a signed/unsigned
comparison when used with a syscall function that returns an unsigned
value such as inet_addr(), which returns in_addr_t, which is defined as
an unsigned int. By casting the result to an int before the macro
processes it, and then casting it back to an in_addr_t after the macro
returns it we are able to avoid the signed/unsigned comparison, and so
avoid the signed/unsigned comparison warning.

Review URL: https://codereview.chromium.org//10907228

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12395 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-14 18:20:24 +00:00
ajohnsen@google.com 0c17bf126c Throw an error if the ServerSocket host argument is invalid.
BUG=

Review URL: https://chromiumcodereview.appspot.com//10917064

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11769 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-03 14:39:47 +00:00
jackpal@google.com e060b66a3e Add _android files for building DartVM on Android
Split directory_posix -> directory_(android|linux|macos)
  This allows us to cleanly make Android-specific changes to
  directory_android.cc

Copy all _linux files to _android files and edit as needed to account
for the differences between Linux and Android:

 + getcwd(0, NULL) doesn't work on Android, have to emulate
 + Android doesn't have a '/tmp' directory, have to emulate
 + Android doesn't provide mkdtemp(), have to emulate.
 + Small differences in the available system include files.
 + Use pthread_cond_timedwait_monotonic instead of
   pthread_condattr_setclock

Review URL: https://chromiumcodereview.appspot.com//10826233

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@10613 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-13 23:06:52 +00:00