in reply to Sending STDERR to a filehandle

change:
$pid = open(ERROR, "$cmd 2>&1 1>/dev/null |");
to
$pid = open(ERROR, "$cmd 1>/dev/null 2>&1 |");
I know that in Unix, putting them the wrong way around causes the same symptoms you are talking about.

Replies are listed 'Best First'.
Re: Re: Sending STDERR to a filehandle
by bobn (Chaplain) on Jun 10, 2003 at 17:08 UTC
    Actually, you're the one that has it backwards. Although most things hapopen letf-to-right, I've always found tht redirections happen right to left. Hence, you've arranged for STDOUT and STDERR both to go to /dev/null.

    --Bob Niederman, http://bob-n.com