Skip to content

Commit b8cfa09

Browse files
committed
Merge branch 'PHP-7.1' into PHP-7.2
* PHP-7.1: Avoid code duplication and don't miss env restore
2 parents da05b7e + 044eb39 commit b8cfa09

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sapi/cgi/cgi_main.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2236,8 +2236,7 @@ consult the installation file that came with this distribution, or visit \n\
22362236
while (parent) {
22372237
EnterCriticalSection(&cleanup_lock);
22382238
if (cleaning_up) {
2239-
DeleteCriticalSection(&cleanup_lock);
2240-
goto parent_out;
2239+
goto parent_loop_end;
22412240
}
22422241
LeaveCriticalSection(&cleanup_lock);
22432242

@@ -2293,6 +2292,7 @@ consult the installation file that came with this distribution, or visit \n\
22932292
WaitForMultipleObjects(kids, kid_cgi_ps, FALSE, INFINITE);
22942293
}
22952294

2295+
parent_loop_end:
22962296
/* restore my env */
22972297
SetEnvironmentVariable("PHP_FCGI_CHILDREN", kid_buf);
22982298

0 commit comments

Comments
 (0)