Hi,
I'm trying to develop a small extension and up until now I've been unable to launch a simple process via subprocess.jsm with standard input.
This is the code snippet I cannot get to work :(
And the output it produces (with debug enabled) is:
subprocess started; got PID 23570
getlimit: maxFD=1024
Creating new stdin worker
sending 5 bytes to stdinWorker
trying to close stdin
sending close stdin to worker
Got msg from stdout: initialising library with libc.so.6
Got msg from stdout: waitpid signaled subprocess stop, exitcode=0
Got msg from stdout: poll returned HUP
Pipe stdout closed
Got msg from stderr: initialising library with libc.so.6
Got msg from stderr: poll returned HUP
Pipe stderr closed
Cleanup called
trying to close stdin
stdinWorker: initialising library with libc.so.6
stdinWorker: trying to write to 50
trying to close stdin
got error from stdinWorker: expected type int, got (void 0)
stdinWorker: closing stdin
Stdin pipe closed
<<ERROR>>
<<SALIDA>>
I've tried to use the stdin function form with the same results.
Thanks.
have you tried just echo? afaik echo is not a good test since it does strange things with stdin/out/err
subprocess.jsm closes stdin after writing to it.
Hi, I'm trying to develop a small extension and up until now I've been unable to launch a simple process via subprocess.jsm with standard input. This is the code snippet I cannot get to work :(
And the output it produces (with debug enabled) is:
I've tried to use the stdin function form with the same results. Thanks.