#26786 [Opn->Fbk]: with CGI, shell_exec()/backtick operator never returns
| From: | sniper@php.net | Date: | Tue, 06 Jan 2004 22:53:54 +0000 |
| Subject: | #26786 [Opn->Fbk]: with CGI, shell_exec()/backtick operator never returns | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-52887@lists.php.net to get a copy of this message | ||
ID: 26786
Updated by: sniper@php.net
Reported By: php dot chad at cropcirclesystems dot net
-Status: Open
+Status: Feedback
Bug Type: CGI related
Operating System: FreeBSD 5.1-p11
PHP Version: 4.3.4
New Comment:
Please try using this CVS snapshot:
http://snaps.php.net/php4-STABLE-latest.tar.gz
For Windows:
http://snaps.php.net/win32/php4-win32-STABLE-latest.zip
Also, I could not access that phpinfo() page.
So put your full configure line here. (or rather, cut it down to bare
minimum, configure the snapshot using that cut down version and test
again)
Previous Comments:
------------------------------------------------------------------------
[2004-01-04 15:18:13] php dot chad at cropcirclesystems dot net
Description:
------------
Using the Apache module or the CLI, everything works
just fine.
However, when using PHP via CGI, the backticks operator
and the shell_exec() function both never return,
however, they DO successfully execute the command! php
blocks idle, not racing.
Seems similar to #11224 in effect, but #11224 claims it
was fixed in 4.0.6! Also, #11224 is on Windows using
IIS! (yuck!)
I've built PHP 4.3.4 via FreeBSD's port system, so it
could be their problem. I have yet to test this with
another operating system. My php.ini is your php.ini-
recommended. My configure line is rather large, but can
be
seen at 'http://www.cropcirclesystems.net/phpinfo.php',
although I have many optional modules, I've also tried
this with FreeBSD's port's default module selections. I
built using: cd /usr/ports/lang/php4; make
WITHOUT_CLI=yes WITHOUT_APACHE=yes install; cp /usr/
local/etc/php.ini-recommended /usr/local/etc/php.ini
Reproduce code:
---------------
<?php
print shell_exec('/full/path/to/some/executable');
?>
Expected result:
----------------
the stdout of the executable
Actual result:
--------------
indefinate waiting. The executable gets executed,
though.
I'd be happy to follow up with more testing/information.
I'll let you know after I try the same thing on FreeBSD
4.9 and Gentoo Linux.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=26786&edit=1