Permalink
Browse files

pass STDIN to subprocess in shell()

... so the child process can read from our STDIN when it creates a prompt.
  • Loading branch information...
FROGGS committed Mar 9, 2014
1 parent 78994df commit abe4c1e5c1740e5cf24ced202ca45dba587289f5
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/io/procops.c
View
@@ -129,7 +129,8 @@ MVMObject * MVM_proc_getenvhash(MVMThreadContext *tc) {
#define SPAWN(shell) do { \
process->data = &result; \
- process_stdio[0].flags = UV_IGNORE; \
+ process_stdio[0].flags = UV_INHERIT_FD; \
+ process_stdio[0].data.fd = 0; \
process_stdio[1].flags = UV_INHERIT_FD; \
process_stdio[1].data.fd = 1; \
process_stdio[2].flags = UV_INHERIT_FD; \

0 comments on commit abe4c1e

Please sign in to comment.