Expose the FD numbers for stdin and stderr on process.binding("stdio")

pull/5370/head
isaacs 2010-06-12 23:03:11 -07:00 committed by Ryan Dahl
parent d6072766ed
commit 1ffdad010b
1 changed files with 2 additions and 0 deletions

View File

@ -199,6 +199,8 @@ void Stdio::Initialize(v8::Handle<v8::Object> target) {
}
target->Set(String::NewSymbol("stdoutFD"), Integer::New(STDOUT_FILENO));
target->Set(String::NewSymbol("stderrFD"), Integer::New(STDERR_FILENO));
target->Set(String::NewSymbol("stdinFD"), Integer::New(STDIN_FILENO));
NODE_SET_METHOD(target, "writeError", WriteError);
NODE_SET_METHOD(target, "openStdin", OpenStdin);