File tree Expand file tree Collapse file tree 2 files changed +26
-1
lines changed Expand file tree Collapse file tree 2 files changed +26
-1
lines changed Original file line number Diff line number Diff line change @@ -735,7 +735,10 @@ static PHP_FUNCTION(swoole_event_rshutdown) {
735
735
if (!sw_reactor ()) {
736
736
return ;
737
737
}
738
- php_swoole_fatal_error (E_DEPRECATED, " Event::wait() in shutdown function is deprecated" );
738
+ // when throw Exception, do not show the info
739
+ if (!sw_reactor ()->bailout ) {
740
+ php_swoole_fatal_error (E_DEPRECATED, " Event::wait() in shutdown function is deprecated" );
741
+ }
739
742
php_swoole_event_wait ();
740
743
}
741
744
zend_end_try ();
Original file line number Diff line number Diff line change
1
+ --TEST--
2
+ swoole_event: deprecated_event_wait
3
+ --SKIPIF--
4
+ <?php
5
+
6
+ use SebastianBergmann \CodeCoverage \Report \PHP ;
7
+
8
+ use function Swoole \Coroutine \run ;
9
+
10
+ require __DIR__ . '/../include/skipif.inc ' ; ?>
11
+ --FILE--
12
+ <?php
13
+ require __DIR__ . '/../include/bootstrap.php ' ;
14
+
15
+ error_reporting (E_ALL & E_DEPRECATED );
16
+
17
+ run (function () {
18
+ throw new Exception ("Error Processing Request " , 1 );
19
+ });
20
+
21
+ ?>
22
+ --EXPECT--
You can’t perform that action at this time.
0 commit comments