com php-src: Merge branch 'PHP-7.0' into PHP-7.1: Zend/zend_s ignal.c

[email protected] (Anatol Belski)
Newsgroups php.cvs
Message-ID <[email protected]>
Commit:    494fc16184ba2899f799d13c9fc4e06e272133a4
Author:    Anatol Belski <[email protected]>         Thu, 2 Mar 2017 16:41:43 +0100
Parents:   bf8c463f5bcb32b83cd6252d7f8cfb171523f353 c7b2c698d03466959874d933b1a44be125e25e4f
Branches:  PHP-7.1 master

Link:       http://git.php.net/?p=php-src.git;a=commitdiff;h=494fc16184ba2899f799d13c9fc4e06e272133a4

Log:
Merge branch 'PHP-7.0' into PHP-7.1

* PHP-7.0:
  do not try to handle signals, when globals are inconsistent

Changed paths:
  MM  Zend/zend_signal.c


Diff:
diff --cc Zend/zend_signal.c
index 605187a,ba550a1..9a21831
--- a/Zend/zend_signal.c
+++ b/Zend/zend_signal.c
@@@ -172,9 -165,16 +177,16 @@@ ZEND_API void zend_signal_handler_unblo
  static void zend_signal_handler(int signo, siginfo_t *siginfo, void *context)
  {
  	int errno_save = errno;
 -	struct sigaction sa = {{0}};
 +	struct sigaction sa;
  	sigset_t sigset;
- 	zend_signal_entry_t p_sig = SIGG(handlers)[signo-1];
+ 	zend_signal_entry_t p_sig;
+ #ifdef ZTS
+ 	if (NULL == TSRMG_BULK_STATIC(zend_signal_globals_id, zend_signal_globals_t *)) {
+ 		p_sig.flags = 0;
+ 		p_sig.handler = SIG_DFL;
+ 	} else 
+ #endif
+ 	p_sig = SIGG(handlers)[signo-1];
  
  	if (p_sig.handler == SIG_DFL) { /* raise default handler */
  		if (sigaction(signo, NULL, &sa) == 0) {
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.