On Sun, Mar 14, 2010 at 3:39 PM, M. <karpe...@ookoo.org> wrote: > Hi, > > Le dimanche 14 mars 2010 à 15:30 +0100, Keisial a écrit : >> Creating a fdopen call is useless, since it needs a previous >> descriptor to >> work from, and all descriptors are equal. Where's that file >> descriptor >> coming >> from? > > When you spawn a new program, you can pass it additionnal descriptors on > top of stdin/stdout/stderr. > > For example look at proc_open(). You can pass more than 3 descriptors, > and communicate if the program is able to use them. > > An alternative on linux is to $fp = fopen("/proc/self/fd/3","r+")
That's what proc_open does and allows. Cheers, -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php