nlopess Tue Jan 2 15:31:58 2007 UTC Modified files: /php-src/ext/standard proc_open.c Log: MFB http://cvs.php.net/viewvc.cgi/php-src/ext/standard/proc_open.c?r1=1.48&r2=1.49&diff_format=u Index: php-src/ext/standard/proc_open.c diff -u php-src/ext/standard/proc_open.c:1.48 php-src/ext/standard/proc_open.c:1.49 --- php-src/ext/standard/proc_open.c:1.48 Mon Jan 1 09:29:32 2007 +++ php-src/ext/standard/proc_open.c Tue Jan 2 15:31:58 2007 @@ -15,7 +15,7 @@ | Author: Wez Furlong <[EMAIL PROTECTED]> | +----------------------------------------------------------------------+ */ -/* $Id: proc_open.c,v 1.48 2007/01/01 09:29:32 sebastian Exp $ */ +/* $Id: proc_open.c,v 1.49 2007/01/02 15:31:58 nlopess Exp $ */ #if 0 && (defined(__linux__) || defined(sun) || defined(__IRIX__)) # define _BSD_SOURCE /* linux wants this when XOPEN mode is on */ @@ -602,8 +602,6 @@ } #endif - - } else if (strcmp(Z_STRVAL_PP(ztype), "file") == 0) { zval **zfile, **zmode; char *filename; @@ -781,7 +779,8 @@ /* clean up all the descriptors */ for (i = 0; i < ndesc; i++) { close(descriptors[i].childend); - close(descriptors[i].parentend); + if (descriptors[i].parentend) + close(descriptors[i].parentend); } php_error_docref(NULL TSRMLS_CC, E_WARNING, "procve failed - %s", strerror(errno)); goto exit_fail; @@ -850,7 +849,8 @@ /* clean up all the descriptors */ for (i = 0; i < ndesc; i++) { close(descriptors[i].childend); - close(descriptors[i].parentend); + if (descriptors[i].parentend) + close(descriptors[i].parentend); } php_error_docref(NULL TSRMLS_CC, E_WARNING, "fork failed - %s", strerror(errno));
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php