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

Issue 85993002: Add UDP support to dart:io (Closed)

Created:
7 years ago by Søren Gjesse
Modified:
7 years ago
Reviewers:
Anders Johnsen
CC:
reviews_dartlang.org, vm-dev_dartlang.org
Visibility:
Public.

Description

Add UDP support to dart:io Initial implementation of UDP support in dart:io Added a RawDatagramSocket which gets the same events as a RawSocket except that READ_CLOSED is never received. The receive from a RawDatagramSocket returns a Datagram object where the senders address and port is presten together with the data. The send on a RawDatagramSocket takes data and the address and port of the destination. Extended the number of socket options to support UDP. Added getting the socket options. R=ajohnsen@google.com BUG=http://dartbug.com/1975 Committed: https://code.google.com/p/dart/source/detail?r=31098

Patch Set 1 #

Total comments: 20

Patch Set 2 : Addressed first round of comments #

Total comments: 30

Patch Set 3 : Addressed review comments #

Patch Set 4 : Rebased to r30794 #

Patch Set 5 : Use isolate data for UDP buffer #

Patch Set 6 : Windows implementation #

Patch Set 7 : Rebased to r31022 #

Patch Set 8 : Android implementation #

Patch Set 9 : Added Mac OS #

Patch Set 10 : Add Mac OS implementation #

Patch Set 11 : Update test #

Total comments: 24

Patch Set 12 : Addressed review commetns #

Patch Set 13 : Fix Windows build #

Unified diffs Side-by-side diffs Delta from patch set Stats (+2137 lines, -53 lines) Patch
M runtime/bin/eventhandler_win.h View 1 2 3 4 5 6 7 8 9 10 11 12 11 chunks +67 lines, -3 lines 0 comments Download
M runtime/bin/eventhandler_win.cc View 1 2 3 4 5 6 7 8 9 10 11 12 chunks +175 lines, -4 lines 0 comments Download
M runtime/bin/io_natives.cc View 1 2 3 4 5 6 7 8 9 1 chunk +7 lines, -1 line 0 comments Download
M runtime/bin/isolate_data.h View 1 2 3 4 1 chunk +4 lines, -1 line 0 comments Download
M runtime/bin/socket.h View 1 2 3 4 5 6 7 8 9 3 chunks +20 lines, -0 lines 0 comments Download
M runtime/bin/socket.cc View 1 2 3 4 5 6 7 8 9 10 11 8 chunks +261 lines, -15 lines 0 comments Download
M runtime/bin/socket_android.cc View 1 2 3 4 5 6 7 6 chunks +200 lines, -5 lines 0 comments Download
M runtime/bin/socket_linux.cc View 1 2 3 4 5 6 7 8 9 6 chunks +202 lines, -5 lines 0 comments Download
M runtime/bin/socket_macos.cc View 1 2 3 4 5 6 7 8 9 6 chunks +252 lines, -5 lines 0 comments Download
M runtime/bin/socket_patch.dart View 1 2 3 4 5 6 7 8 9 8 chunks +288 lines, -7 lines 0 comments Download
M runtime/bin/socket_win.cc View 1 2 3 4 5 6 7 8 9 5 chunks +211 lines, -7 lines 0 comments Download
M sdk/lib/_internal/lib/io_patch.dart View 1 2 3 4 5 6 1 chunk +7 lines, -0 lines 0 comments Download
M sdk/lib/io/socket.dart View 1 2 3 2 chunks +135 lines, -0 lines 0 comments Download
A tests/standalone/io/raw_datagram_socket_test.dart View 1 2 3 4 5 6 7 8 9 10 1 chunk +305 lines, -0 lines 0 comments Download
M tests/standalone/standalone.status View 1 2 3 4 5 6 7 8 9 1 chunk +3 lines, -0 lines 0 comments Download

Messages

Total messages: 8 (0 generated)
Søren Gjesse
Linux implementation only for now. We could consider sharing some of the code between RawSocket ...
7 years ago (2013-11-25 16:35:47 UTC) #1
Anders Johnsen
First round of interface comments. Yay for UDP! :) https://codereview.chromium.org/85993002/diff/1/sdk/lib/io/socket.dart File sdk/lib/io/socket.dart (right): https://codereview.chromium.org/85993002/diff/1/sdk/lib/io/socket.dart#newcode321 sdk/lib/io/socket.dart:321: ...
7 years ago (2013-11-25 18:00:06 UTC) #2
Søren Gjesse
ptal https://codereview.chromium.org/85993002/diff/1/sdk/lib/io/socket.dart File sdk/lib/io/socket.dart (right): https://codereview.chromium.org/85993002/diff/1/sdk/lib/io/socket.dart#newcode321 sdk/lib/io/socket.dart:321: static const SocketOption _IP_MULTICAST_LOOP = const SocketOption._(1); On ...
7 years ago (2013-11-28 13:58:52 UTC) #3
Anders Johnsen
https://codereview.chromium.org/85993002/diff/20001/runtime/bin/socket.cc File runtime/bin/socket.cc (right): https://codereview.chromium.org/85993002/diff/20001/runtime/bin/socket.cc#newcode136 runtime/bin/socket.cc:136: OSError error; Unused? https://codereview.chromium.org/85993002/diff/20001/runtime/bin/socket.cc#newcode265 runtime/bin/socket.cc:265: if (drop_datagrams) { Drop ...
7 years ago (2013-11-29 12:36:54 UTC) #4
Søren Gjesse
PTAL Implementation for all Platforms. The Android code has been verified to compile, and we ...
7 years ago (2013-12-12 11:38:46 UTC) #5
Anders Johnsen
LGTM, yay, this is very cool! :) Adding isMulticastEnabled may help on mac (I read ...
7 years ago (2013-12-12 12:19:58 UTC) #6
Søren Gjesse
https://codereview.chromium.org/85993002/diff/190001/runtime/bin/eventhandler_win.cc File runtime/bin/eventhandler_win.cc (right): https://codereview.chromium.org/85993002/diff/190001/runtime/bin/eventhandler_win.cc#newcode39 runtime/bin/eventhandler_win.cc:39: if (operation == kRecvFrom) { On 2013/12/12 12:19:58, Anders ...
7 years ago (2013-12-12 15:44:38 UTC) #7
Søren Gjesse
7 years ago (2013-12-12 15:45:41 UTC) #8
Message was sent while issue was closed.
Committed patchset #13 manually as r31098 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698