diff options
-rw-r--r-- | TSRM/TSRM.h | 2 | ||||
-rw-r--r-- | Zend/Zend.m4 | 1 | ||||
-rw-r--r-- | Zend/zend_alloc.c | 4 | ||||
-rw-r--r-- | Zend/zend_signal.c | 3 | ||||
-rw-r--r-- | Zend/zend_signal.h | 4 | ||||
-rw-r--r-- | ext/standard/exec.c | 3 | ||||
-rw-r--r-- | ext/standard/mail.c | 2 | ||||
-rw-r--r-- | ext/standard/proc_open.c | 2 | ||||
-rw-r--r-- | main/main.c | 4 | ||||
-rw-r--r-- | sapi/cgi/cgi_main.c | 6 | ||||
-rw-r--r-- | sapi/cli/php_cli.c | 11 | ||||
-rw-r--r-- | sapi/cli/php_cli_server.c | 4 | ||||
-rw-r--r-- | sapi/embed/php_embed.c | 2 | ||||
-rw-r--r-- | sapi/fpm/fpm/fpm_main.c | 6 | ||||
-rw-r--r-- | sapi/litespeed/lsapi_main.c | 7 | ||||
-rw-r--r-- | sapi/phpdbg/phpdbg.h | 2 |
16 files changed, 11 insertions, 52 deletions
diff --git a/TSRM/TSRM.h b/TSRM/TSRM.h index 5e1f8164ee..64661c1ebf 100644 --- a/TSRM/TSRM.h +++ b/TSRM/TSRM.h @@ -82,9 +82,7 @@ typedef int ts_rsrc_id; # define MUTEX_T st_mutex_t #endif -#ifdef HAVE_SIGNAL_H #include <signal.h> -#endif typedef void (*ts_allocate_ctor)(void *); typedef void (*ts_allocate_dtor)(void *); diff --git a/Zend/Zend.m4 b/Zend/Zend.m4 index c0ada26aea..0755a58f14 100644 --- a/Zend/Zend.m4 +++ b/Zend/Zend.m4 @@ -12,7 +12,6 @@ malloc.h \ unistd.h \ sys/types.h \ sys/time.h \ -signal.h \ unix.h \ cpuid.h \ dlfcn.h) diff --git a/Zend/zend_alloc.c b/Zend/zend_alloc.c index 77474c5527..3531e79df4 100644 --- a/Zend/zend_alloc.c +++ b/Zend/zend_alloc.c @@ -57,10 +57,8 @@ #include "zend_operators.h" #include "zend_multiply.h" #include "zend_bitset.h" +#include <signal.h> -#ifdef HAVE_SIGNAL_H -# include <signal.h> -#endif #ifdef HAVE_UNISTD_H # include <unistd.h> #endif diff --git a/Zend/zend_signal.c b/Zend/zend_signal.c index 571d85f848..3e9fd227ac 100644 --- a/Zend/zend_signal.c +++ b/Zend/zend_signal.c @@ -30,10 +30,7 @@ #include "zend.h" #include "zend_globals.h" - -#ifdef HAVE_SIGNAL_H #include <signal.h> -#endif #ifdef HAVE_UNISTD_H #include <unistd.h> diff --git a/Zend/zend_signal.h b/Zend/zend_signal.h index 1c234b0a0c..0bb191db73 100644 --- a/Zend/zend_signal.h +++ b/Zend/zend_signal.h @@ -23,9 +23,7 @@ #ifdef ZEND_SIGNALS -# ifdef HAVE_SIGNAL_H -# include <signal.h> -# endif +#include <signal.h> #ifndef NSIG #define NSIG 65 diff --git a/ext/standard/exec.c b/ext/standard/exec.c index 3839945836..e21dbacd5f 100644 --- a/ext/standard/exec.c +++ b/ext/standard/exec.c @@ -31,9 +31,8 @@ #if HAVE_SYS_WAIT_H #include <sys/wait.h> #endif -#if HAVE_SIGNAL_H + #include <signal.h> -#endif #if HAVE_SYS_TYPES_H #include <sys/types.h> diff --git a/ext/standard/mail.c b/ext/standard/mail.c index 53f75bf32a..c1a21c4059 100644 --- a/ext/standard/mail.c +++ b/ext/standard/mail.c @@ -35,10 +35,8 @@ #endif #if PHP_SIGCHILD -#if HAVE_SIGNAL_H #include <signal.h> #endif -#endif #include "php_syslog.h" #include "php_mail.h" diff --git a/ext/standard/proc_open.c b/ext/standard/proc_open.c index d8c7615d4b..326cfc1431 100644 --- a/ext/standard/proc_open.c +++ b/ext/standard/proc_open.c @@ -38,9 +38,7 @@ #if HAVE_SYS_WAIT_H #include <sys/wait.h> #endif -#if HAVE_SIGNAL_H #include <signal.h> -#endif #if HAVE_SYS_STAT_H #include <sys/stat.h> diff --git a/main/main.c b/main/main.c index de0d042843..95f6157d45 100644 --- a/main/main.c +++ b/main/main.c @@ -39,9 +39,9 @@ #if HAVE_UNISTD_H #include <unistd.h> #endif -#if HAVE_SIGNAL_H + #include <signal.h> -#endif + #if HAVE_SETLOCALE #include <locale.h> #endif diff --git a/sapi/cgi/cgi_main.c b/sapi/cgi/cgi_main.c index b22d37f89b..8a461d8c44 100644 --- a/sapi/cgi/cgi_main.c +++ b/sapi/cgi/cgi_main.c @@ -45,9 +45,7 @@ # include <unistd.h> #endif -#if HAVE_SIGNAL_H -# include <signal.h> -#endif +#include <signal.h> #if HAVE_SETLOCALE # include <locale.h> @@ -1779,7 +1777,6 @@ int main(int argc, char *argv[]) char *decoded_query_string; int skip_getopt = 0; -#ifdef HAVE_SIGNAL_H #if defined(SIGPIPE) && defined(SIG_IGN) signal(SIGPIPE, SIG_IGN); /* ignore SIGPIPE in standalone mode so that sockets created via fsockopen() @@ -1788,7 +1785,6 @@ int main(int argc, char *argv[]) does that for us! thies@thieso.net 20000419 */ #endif -#endif #ifdef ZTS php_tsrm_startup(); diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index 4333487a0b..364fd13106 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -46,9 +46,9 @@ #if HAVE_UNISTD_H #include <unistd.h> #endif -#if HAVE_SIGNAL_H + #include <signal.h> -#endif + #if HAVE_SETLOCALE #include <locale.h> #endif @@ -66,10 +66,6 @@ #include "win32/php_registry.h" #endif -#if HAVE_SIGNAL_H -#include <signal.h> -#endif - #ifdef __riscos__ #include <unixlib/local.h> #endif @@ -1233,7 +1229,6 @@ int main(int argc, char *argv[]) } #endif -#ifdef HAVE_SIGNAL_H #if defined(SIGPIPE) && defined(SIG_IGN) signal(SIGPIPE, SIG_IGN); /* ignore SIGPIPE in standalone mode so that sockets created via fsockopen() @@ -1242,8 +1237,6 @@ int main(int argc, char *argv[]) does that for us! thies@thieso.net 20000419 */ #endif -#endif - #ifdef ZTS php_tsrm_startup(); diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index deb61816a7..c814b73f26 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -43,9 +43,7 @@ #if HAVE_UNISTD_H #include <unistd.h> #endif -#if HAVE_SIGNAL_H #include <signal.h> -#endif #if HAVE_SETLOCALE #include <locale.h> #endif @@ -2601,7 +2599,7 @@ int do_cli_server(int argc, char **argv) /* {{{ */ PHP_VERSION, buf, server_bind_address, document_root); } -#if defined(HAVE_SIGNAL_H) && defined(SIGINT) +#if defined(SIGINT) signal(SIGINT, php_cli_server_sigint_handler); zend_signal_init(); #endif diff --git a/sapi/embed/php_embed.c b/sapi/embed/php_embed.c index 4fcb181cc0..d651f6b491 100644 --- a/sapi/embed/php_embed.c +++ b/sapi/embed/php_embed.c @@ -159,7 +159,6 @@ EMBED_SAPI_API int php_embed_init(int argc, char **argv) { zend_llist global_vars; -#ifdef HAVE_SIGNAL_H #if defined(SIGPIPE) && defined(SIG_IGN) signal(SIGPIPE, SIG_IGN); /* ignore SIGPIPE in standalone mode so that sockets created via fsockopen() @@ -168,7 +167,6 @@ EMBED_SAPI_API int php_embed_init(int argc, char **argv) does that for us! thies@thieso.net 20000419 */ #endif -#endif #ifdef ZTS php_tsrm_startup(); diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index 307c02ed7c..3c637d5990 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -43,9 +43,7 @@ # include <unistd.h> #endif -#if HAVE_SIGNAL_H -# include <signal.h> -#endif +#include <signal.h> #if HAVE_SETLOCALE # include <locale.h> @@ -1567,7 +1565,6 @@ int main(int argc, char *argv[]) zend_bool old_rc_debug; #endif -#ifdef HAVE_SIGNAL_H #if defined(SIGPIPE) && defined(SIG_IGN) signal(SIGPIPE, SIG_IGN); /* ignore SIGPIPE in standalone mode so that sockets created via fsockopen() @@ -1576,7 +1573,6 @@ int main(int argc, char *argv[]) does that for us! thies@thieso.net 20000419 */ #endif -#endif #ifdef ZTS php_tsrm_startup(); diff --git a/sapi/litespeed/lsapi_main.c b/sapi/litespeed/lsapi_main.c index 2d8eb75326..4a6b1a0f3f 100644 --- a/sapi/litespeed/lsapi_main.c +++ b/sapi/litespeed/lsapi_main.c @@ -43,12 +43,7 @@ #endif -#if HAVE_SIGNAL_H - #include <signal.h> - -#endif - #include <sys/socket.h> #include <arpa/inet.h> #include <netinet/in.h> @@ -1228,11 +1223,9 @@ int main( int argc, char * argv[] ) int slow_script_msec = 0; char time_buf[40]; -#ifdef HAVE_SIGNAL_H #if defined(SIGPIPE) && defined(SIG_IGN) signal(SIGPIPE, SIG_IGN); #endif -#endif #ifdef ZTS php_tsrm_startup(); diff --git a/sapi/phpdbg/phpdbg.h b/sapi/phpdbg/phpdbg.h index c2298037d4..d1b22e6f40 100644 --- a/sapi/phpdbg/phpdbg.h +++ b/sapi/phpdbg/phpdbg.h @@ -46,7 +46,7 @@ #include "zend_ini_scanner.h" #include "zend_stream.h" #include "zend_signal.h" -#if !defined(_WIN32) && !defined(ZEND_SIGNALS) && defined(HAVE_SIGNAL_H) +#if !defined(_WIN32) && !defined(ZEND_SIGNALS) # include <signal.h> #elif defined(PHP_WIN32) # include "win32/signal.h" |