File tree Expand file tree Collapse file tree 3 files changed +46
-1
lines changed Expand file tree Collapse file tree 3 files changed +46
-1
lines changed Original file line number Diff line number Diff line change 7
7
Spagnoletti)
8
8
9
9
- FPM:
10
+ . Fixed bug #77934 (php-fpm kill -USR2 not working). (Jakub Zelenka)
10
11
. Fixed bug #77921 (static.php.net doesn't work anymore). (Peter Kokot)
11
12
12
13
- GD:
Original file line number Diff line number Diff line change @@ -142,7 +142,7 @@ static void sig_soft_quit(int signo) /* {{{ */
142
142
int saved_errno = errno ;
143
143
144
144
/* closing fastcgi listening socket will force fcgi_accept() exit immediately */
145
- close (0 );
145
+ close (fpm_globals . listening_socket );
146
146
if (0 > socket (AF_UNIX , SOCK_STREAM , 0 )) {
147
147
zlog (ZLOG_WARNING , "failed to create a new socket" );
148
148
}
Original file line number Diff line number Diff line change
1
+ --TEST--
2
+ FPM: bug77934 - php-fpm kill -USR2 not working
3
+ --SKIPIF--
4
+ <?php include "skipif.inc " ; ?>
5
+ --FILE--
6
+ <?php
7
+
8
+ require_once "tester.inc " ;
9
+
10
+ $ cfg = <<<EOT
11
+ [global]
12
+ error_log = {{FILE:LOG}}
13
+ pid = {{FILE:PID}}
14
+ process_control_timeout=20
15
+ [unconfined]
16
+ listen = {{ADDR}}
17
+ pm = dynamic
18
+ pm.max_children = 5
19
+ pm.start_servers = 1
20
+ pm.min_spare_servers = 1
21
+ pm.max_spare_servers = 1
22
+ EOT ;
23
+
24
+ $ tester = new FPM \Tester ($ cfg );
25
+ $ tester ->start ();
26
+ $ tester ->expectLogStartNotices ();
27
+ $ tester ->signal ('USR2 ' );
28
+ $ tester ->expectLogNotice ('Reloading in progress ... ' );
29
+ $ tester ->expectLogNotice ('reloading: .* ' );
30
+ $ tester ->expectLogNotice ('using inherited socket fd=\d+, "127.0.0.1:\d+" ' );
31
+ $ tester ->expectLogStartNotices ();
32
+ $ tester ->terminate ();
33
+ $ tester ->expectLogTerminatingNotices ();
34
+ $ tester ->close ();
35
+
36
+ ?>
37
+ Done
38
+ --EXPECT--
39
+ Done
40
+ --CLEAN--
41
+ <?php
42
+ require_once "tester.inc " ;
43
+ FPM \Tester::clean ();
44
+ ?>
You can’t perform that action at this time.
0 commit comments