Skip to content

Commit

Permalink
fix closing standard fds on node
Browse files Browse the repository at this point in the history
  • Loading branch information
luite committed May 22, 2015
1 parent 4f2af22 commit 9b196ff
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions pkg/base.js
Original file line number Diff line number Diff line change
Expand Up @@ -518,8 +518,8 @@ if(h$isNode) {

h$base_closeStdin = function(fd, fdo, c) {
TRACE_IO("close stdin");
process.stdin.close();
c();
// process.stdin.close(); fixme
c(0);
}

h$base_writeFile = function(fd, fdo, buf, buf_offset, n, c) {
Expand Down Expand Up @@ -550,8 +550,8 @@ if(h$isNode) {

h$base_closeStdout = function(fd, fdo, c) {
TRACE_IO("close stdout");
process.stdout.close();
c();
// not actually closed, fixme?
c(0);
}

h$base_writeStderr = function(fd, fdo, buf, buf_offset, n, c) {
Expand All @@ -561,8 +561,8 @@ if(h$isNode) {

h$base_closeStderr = function(fd, fdo, c) {
TRACE_IO("close stderr");
process.stderr.close();
c();
// not actually closed, fixme?
c(0);
}

process.stdin.on('readable', h$base_process_stdin);
Expand Down

2 comments on commit 9b196ff

@cstrahan
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just curious, why did those lines have to be commented out?

@hvr
Copy link

@hvr hvr commented on 9b196ff Jun 11, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@cstrahan probably due to ghcjs/ghcjs#348

Please sign in to comment.