cvs: php4 /ext/standard/tests/general_functions proc_open.phpt
| From: | James E. Flemer | Date: | Sat, 03 Aug 2002 14:54:30 +0000 |
| Subject: | cvs: php4 /ext/standard/tests/general_functions proc_open.phpt | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-13106@lists.php.net to get a copy of this message | ||
jflemer Sat Aug 3 10:54:30 2002 EDT
Modified files:
/php4/ext/standard/tests/general_functions proc_open.phpt
Log:
Close pipes to avoid deadlock.
Submitted By: Melvyn Sopacua <msopacua@idg.nl>
Index: php4/ext/standard/tests/general_functions/proc_open.phpt
diff -u php4/ext/standard/tests/general_functions/proc_open.phpt:1.1
php4/ext/standard/tests/general_functions/proc_open.phpt:1.2
--- php4/ext/standard/tests/general_functions/proc_open.phpt:1.1 Thu May 23 06:46:06 2002
+++ php4/ext/standard/tests/general_functions/proc_open.phpt Sat Aug 3 10:54:30 2002
@@ -20,6 +20,12 @@
$pipes
);
+/* As per manual: avoid deadlock */
+for ($i = 0; $i < count($pipes); $i++)
+{
+ fclose($pipes[$i]);
+}
+
proc_close($cat);
echo "I didn't segfault!\n";