summaryrefslogtreecommitdiff
path: root/sapi/cgi
diff options
context:
space:
mode:
Diffstat (limited to 'sapi/cgi')
-rw-r--r--sapi/cgi/cgi_main.c11
-rw-r--r--sapi/cgi/config9.m44
2 files changed, 10 insertions, 5 deletions
diff --git a/sapi/cgi/cgi_main.c b/sapi/cgi/cgi_main.c
index 538377328..459ceb985 100644
--- a/sapi/cgi/cgi_main.c
+++ b/sapi/cgi/cgi_main.c
@@ -20,7 +20,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: cgi_main.c,v 1.256.2.4 2005/02/11 02:06:48 sniper Exp $ */
+/* $Id: cgi_main.c,v 1.256.2.6 2005/04/28 14:24:21 sniper Exp $ */
#include "php.h"
#include "php_globals.h"
@@ -482,9 +482,14 @@ static void sapi_cgi_register_variables(zval *track_vars_array TSRMLS_DC)
static void sapi_cgi_log_message(char *message)
{
#if PHP_FASTCGI
+ long logging = 1;
TSRMLS_FETCH();
- if (!FCGX_IsCGI()) {
+ if (cfg_get_long("fastcgi.logging", &logging) == FAILURE) {
+ logging = 1;
+ }
+
+ if (!FCGX_IsCGI() && logging) {
FCGX_Request *request = (FCGX_Request *)SG(server_context);
FCGX_FPrintF( request->err, "%s\n", message );
/* ignore return code */
@@ -971,7 +976,7 @@ int main(int argc, char *argv[])
int fcgi_fd = 0;
FCGX_Request request;
#ifdef PHP_WIN32
- int impersonate = 0;
+ long impersonate = 0;
#else
int status = 0;
#endif
diff --git a/sapi/cgi/config9.m4 b/sapi/cgi/config9.m4
index c4d27771f..6c969c7b2 100644
--- a/sapi/cgi/config9.m4
+++ b/sapi/cgi/config9.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: config9.m4,v 1.12.2.2 2005/03/06 23:16:53 sniper Exp $
+dnl $Id: config9.m4,v 1.12.2.3 2005/04/21 15:13:16 sniper Exp $
dnl
AC_ARG_ENABLE(cgi,
@@ -149,7 +149,7 @@ if test "$PHP_SAPI" = "default"; then
AC_DEFINE_UNQUOTED(PHP_FCGI_STATIC, $PHP_FCGI_STATIC, [ ])
AC_MSG_RESULT($PHP_ENABLE_FASTCGI)
- INSTALL_IT="@echo \"Installing PHP CGI into: \$(INSTALL_ROOT)\$(bindir)/\"; \$(INSTALL) -m 0755 \$(SAPI_CGI_PATH) \$(INSTALL_ROOT)\$(bindir)/\$(program_prefix)php\$(program_suffix)"
+ INSTALL_IT="@echo \"Installing PHP CGI into: \$(INSTALL_ROOT)\$(bindir)/\"; \$(INSTALL) -m 0755 \$(SAPI_CGI_PATH) \$(INSTALL_ROOT)\$(bindir)/\$(program_prefix)php\$(program_suffix)\$(EXEEXT)"
PHP_SELECT_SAPI(cgi, program, $PHP_FCGI_FILES cgi_main.c getopt.c, $PHP_FCGI_INCLUDE, '$(SAPI_CGI_PATH)')
case $host_alias in