]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
Provide Win32 users a log of the cgi command invoked, to assist
authorWilliam A. Rowe Jr <wrowe@apache.org>
Thu, 21 Mar 2002 05:56:52 +0000 (05:56 +0000)
committerWilliam A. Rowe Jr <wrowe@apache.org>
Thu, 21 Mar 2002 05:56:52 +0000 (05:56 +0000)
  in debugging scripts, at LogLevel info.  Also provide env vars
  at LogLevel debug for additional help to admins troubleshooting
  the ever mysterious "Premature end of script headers" error.
  Since this is the single most common cause of trouble reports on
  the newslist, at least this gives us something to point users at.
  [Aaron Bannert]

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/1.3.x@94073 13f79535-47bb-0310-9956-ffa450edef68

src/main/util_script.c

index 5b4a6e492cf4b96eac3635c32856869b518d04b5..80861d6fde25056f240af40e7883842f65082a6c 100644 (file)
@@ -1153,6 +1153,13 @@ API_EXPORT(int) ap_call_exec(request_rec *r, child_info *pinfo, char *argv0,
             i++;
         }
 
+        ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, r->server,
+                     "Invoking CGI Command '%s'", pCommand);
+        for (i = 0; env[i]; ++i) {
+            ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_DEBUG, r->server,
+                         "  CGI env[%d] = '%s'", i, env[i]);
+        }
+
         if (CreateProcess(NULL, pCommand, NULL, NULL, TRUE, 
                           0,
                           pEnvBlock,