com php-src: Avoid code duplication and don't miss env restore: sapi/cgi/cgi_main.c

From: Date: Wed, 03 Oct 2018 12:32:52 +0000
Subject: com php-src: Avoid code duplication and don't miss env restore: sapi/cgi/cgi_main.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-103334@lists.php.net to get a copy of this message
Commit: 044eb39e633c91d55b339415ee5749a46496ffd9 Author: Anatol Belski <ab@php.net> Wed, 3 Oct 2018 14:32:52 +0200 Parents: b0547a3dfba6702e7cc94476d4d422374c20b4b8 Branches: PHP-7.1 PHP-7.2 PHP-7.3 master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=044eb39e633c91d55b339415ee5749a46496ffd9 Log: Avoid code duplication and don't miss env restore Changed paths: M sapi/cgi/cgi_main..c Diff: diff --git a/sapi/cgi/cgi_main.c b/sapi/cgi/cgi_main.c index d571cf0..fda2429 100644 --- a/sapi/cgi/cgi_main.c +++ b/sapi/cgi/cgi_main.c @@ -2242,8 +2242,7 @@ consult the installation file that came with this distribution, or visit \n\ while (parent) { EnterCriticalSection(&cleanup_lock); if (cleaning_up) { - DeleteCriticalSection(&cleanup_lock); - goto parent_out; + goto parent_loop_end; } LeaveCriticalSection(&cleanup_lock); @@ -2299,6 +2298,7 @@ consult the installation file that came with this distribution, or visit \n\ WaitForMultipleObjects(kids, kid_cgi_ps, FALSE, INFINITE); } +parent_loop_end: /* restore my env */ SetEnvironmentVariable("PHP_FCGI_CHILDREN", kid_buf);

« previous php.cvs (#103334) next »