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

Issue 9360040: Handle stdio redirection in standalone VM (Closed)

Created:
8 years, 10 months ago by Søren Gjesse
Modified:
8 years, 10 months ago
Reviewers:
Ivan Posva
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Handle stdio redirection in standalone VM The recent change to epoll on Linux and kqueue on Mac OS for getting notifications from file descriptors caused the redirection of stdin, stdout and stderr for the stand alone VM to stop working. On Linux epoll failed when file descriptor 0, 1 or 2 redirected from or to a file war registered. On Mac OS there was just no events generated from kqueue. The streams created for stdio, stdout and stderr is now of the correct type and for file redirections no longer a socket object holding a file descriptor for a regular file. Added testing of stdio redirection using both pipes and files. These tests are currently skipped on Windows. Fixed handlin of short socket read when reading the process exit code. Always close the socket port when not waiting for any events. R=iposva@google.com BUG= TEST= Committed: https://code.google.com/p/dart/source/detail?r=4226

Patch Set 1 #

Patch Set 2 : Add Mac OS implementation - still unimplemented on Windows #

Patch Set 3 : Add Windows implementation #

Patch Set 4 : Revert test change #

Unified diffs Side-by-side diffs Delta from patch set Stats (+286 lines, -18 lines) Patch
M runtime/bin/builtin_natives.cc View 1 chunk +2 lines, -0 lines 0 comments Download
M runtime/bin/eventhandler_linux.cc View 2 chunks +2 lines, -1 line 0 comments Download
M runtime/bin/file.h View 4 chunks +13 lines, -1 line 0 comments Download
M runtime/bin/file.cc View 2 chunks +19 lines, -1 line 0 comments Download
M runtime/bin/file_impl.dart View 4 chunks +22 lines, -0 lines 0 comments Download
M runtime/bin/file_linux.cc View 2 chunks +20 lines, -0 lines 0 comments Download
M runtime/bin/file_macos.cc View 1 2 chunks +20 lines, -0 lines 0 comments Download
M runtime/bin/file_win.cc View 1 2 2 chunks +13 lines, -0 lines 0 comments Download
M runtime/bin/process_impl.dart View 1 chunk +3 lines, -3 lines 0 comments Download
M runtime/bin/socket_impl.dart View 1 chunk +7 lines, -0 lines 0 comments Download
M runtime/bin/stdio.dart View 1 chunk +51 lines, -12 lines 0 comments Download
A tests/standalone/src/DartStdIOPipeTest.dart View 1 chunk +101 lines, -0 lines 0 comments Download
A tests/standalone/src/DartStdIOPipeTest.sh View 1 chunk +13 lines, -0 lines 0 comments Download

Messages

Total messages: 2 (0 generated)
Søren Gjesse
8 years, 10 months ago (2012-02-14 14:48:27 UTC) #1
Ivan Posva
8 years, 10 months ago (2012-02-14 15:12:09 UTC) #2
LGTM -ip

Powered by Google App Engine
This is Rietveld 408576698