]> granicus.if.org Git - apache/commitdiff
Fix uninitialized gprof directory name in prefork MPM.
authorJeff Trawick <trawick@apache.org>
Fri, 7 Nov 2003 13:40:04 +0000 (13:40 +0000)
committerJeff Trawick <trawick@apache.org>
Fri, 7 Nov 2003 13:40:04 +0000 (13:40 +0000)
PR:           24450
Submitted by: Chris Knight <Christopher.D.Knight@nasa.gov>
Reviewed by:  Jeff Trawick

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@101714 13f79535-47bb-0310-9956-ffa450edef68

CHANGES
server/mpm/prefork/prefork.c

diff --git a/CHANGES b/CHANGES
index cff834bed4fd6f94bdcd17260fba2b8a68aff06d..3e073e40271da22d10e3f117664a3332b5f7db24 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -2,6 +2,9 @@ Changes with Apache 2.1.0-dev
 
   [Remove entries to the current 2.0 section below, when backported]
 
+  *) Fix uninitialized gprof directory name in prefork MPM.  PR 24450.
+     [Chris Knight <Christopher.D.Knight@nasa.gov>]
+
   *) mod_auth_ldap: Fix some segfaults in the cache logic.  PR 18756.
      [Matthieu Estrade <apache@moresecurity.org>]
 
index e1c01178d30463d278e76db3f70a13540ae31304..3867c0ee9366decf2dd729983b3e54e1a3133767 100644 (file)
@@ -203,7 +203,10 @@ static void chdir_for_gprof(void)
        if(*(dir + len) == '%') {
            dir[len] = '\0';
            apr_snprintf(buf, sizeof(buf), "%sgprof.%d", dir, (int)getpid());
-       } 
+       }
+        else {
+            buf[0] = '\0';
+        }
        use_dir = ap_server_root_relative(pconf, buf[0] ? buf : dir);
        res = apr_dir_make(use_dir,
                            APR_UREAD | APR_UWRITE | APR_UEXECUTE |