Browse Source

Fixed win32 build.

Fixed building of libfcgi when PHP is built from another directory.
Added missing headers needed for wait().
Removed duplicate signal.h header.
Removed unneeded variables.
PEAR_1_4DEV
Ilia Alshanetsky 23 years ago
parent
commit
9c1be88844
  1. 17
      sapi/cgi/cgi_main.c
  2. 2
      sapi/cgi/libfcgi/include/fcgi_config.h

17
sapi/cgi/cgi_main.c

@ -48,6 +48,12 @@
#if HAVE_SETLOCALE
#include <locale.h>
#endif
#if HAVE_SYS_TYPES_H
#include <sys/types.h>
#endif
#if HAVE_SYS_WAIT_H
#include <sys/wait.h>
#endif
#include "zend.h"
#include "zend_extensions.h"
#include "php_ini.h"
@ -61,10 +67,6 @@
#include "win32/php_registry.h"
#endif
#if HAVE_SIGNAL_H
#include <signal.h>
#endif
#ifdef __riscos__
#include <unixlib/local.h>
#endif
@ -271,7 +273,11 @@ static void sapi_cgibin_flush(void *server_context)
#if PHP_FASTCGI
if (!FCGX_IsCGI()) {
FCGX_Request *request = (FCGX_Request *)server_context;
if (!parent && (!request || FCGX_FFlush(request->out) == -1)) {
if (
#ifdef PHP_WIN32
!parent &&
#endif
(!request || FCGX_FFlush(request->out) == -1)) {
php_handle_aborted_connection();
}
return;
@ -1177,7 +1183,6 @@ consult the installation file that came with this distribution, or visit \n\
if( children ) {
int running = 0;
int i;
pid_t pid;
/* Create a process group for ourself & children */

2
sapi/cgi/libfcgi/include/fcgi_config.h

@ -2,6 +2,6 @@
#ifdef _WIN32
#include "fcgi_config_win32.h"
#else
#include "main/php_config.h"
#include "php_config.h"
#endif
Loading…
Cancel
Save