in reply to Re: open()
in thread Close() sometimes fails after open() pipe from command

Your command returned exit status 1 (e.g., a Perl script might have done exit 1; or similar). See the documentation of $? for more details of this variable. Consult the documentation for <samp>$command</samp> to know what went wrong.