Re: Re: CLI issue: Changing STDERR

From: Date: Tue, 15 Mar 2005 01:57:12 +0000
Subject: Re: Re: CLI issue: Changing STDERR
References: 1 2 3  Groups: php.internals 
Request: Send a blank email to internals+get-15448@lists.php.net to get a copy of this message
On Mar 15, 2005, at 2:36, Davy Durham wrote:
Iteresting.. but no, that won't work because the redirection is a construct of a running shell.. not the exec system function that would be interpreting that line. That got me thinking tho.. to try something like #!/bin/bash -c exec /usr/bin/php 2>/path/filename which would seem to maybe work if the php interpreter got the rest of the file as input. But, apparently bash isn't liking -c after it's already been used on a sh-bang. :(
Its not bash, it's your kernel limitation (i guess linux). Most unix kernels allow only bin name + 1 arg on the shebang line. FreeBSD is a notable exception here. Edin

« previous php.internals (#15448) next »