com php-src: Fixed reference counting: ext/standard/proc_open .c

From: Date: Wed, 09 Apr 2014 14:11:18 +0000
Subject: com php-src: Fixed reference counting: ext/standard/proc_open .c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-77450@lists.php.net to get a copy of this message
Commit: b1d2efcc2d3f79016698a3b5091c9be0b7274876 Author: Dmitry Stogov <dmitry@zend.com> Wed, 9 Apr 2014 18:11:18 +0400 Parents: 8732f5e5d7757664703d96407f2adaec2ec3c5dc Branches: phpng Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=b1d2efcc2d3f79016698a3b5091c9be0b7274876 Log: Fixed reference counting Changed paths: M ext/standard/proc_open.c Diff: diff --git a/ext/standard/proc_open.c b/ext/standard/proc_open.c index a72184c..fd3e0c2 100644 --- a/ext/standard/proc_open.c +++ b/ext/standard/proc_open.c @@ -216,7 +216,9 @@ static void proc_open_rsrc_dtor(zend_resource *rsrc TSRMLS_DC) /* Close all handles to avoid a deadlock */ for (i = 0; i < proc->npipes; i++) { if (proc->pipes[i] != 0) { - zend_list_delete(proc->pipes[i]); + if (--GC_REFCOUNT(proc->pipes[i]) <= 0) { + zend_list_delete(proc->pipes[i]); + } proc->pipes[i] = 0; } }

« previous php.cvs (#77450) next »