]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
Some comments... Yes, a 64 char array is overkill, but so
authorJim Jagielski <jim@apache.org>
Fri, 1 Jun 2007 23:36:11 +0000 (23:36 +0000)
committerJim Jagielski <jim@apache.org>
Fri, 1 Jun 2007 23:36:11 +0000 (23:36 +0000)
what :) Also, in this section we later on unset as well,
but also encapsulate the logic here as well.

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

src/main/http_main.c

index 00afe7b2aa96a10ef5001e91b97d4bbc2ba476cb..e59e900bc99a52b60c6c27f0d10f06126c21ef02 100644 (file)
@@ -382,8 +382,9 @@ API_VAR_EXPORT int ap_change_shmem_uid = 0;
 /*
  * Check the pid table to see if the actual pid exists
  */
+
 static int in_pid_table(int pid) {
-    char apid[64];
+    char apid[64];      /* WAY generous! */
     const char *spid;
     snprintf(apid, sizeof(apid), "%d", pid);
     spid = ap_table_get(pid_table, apid);
@@ -2934,7 +2935,7 @@ int reap_children(ap_wait_t *status)
                     ap_update_child_status(n, SERVER_DEAD, NULL);
                     /* just mark it as having a successful exit status */
                     bzero((char *) status, sizeof(ap_wait_t));
-                    unset_pid_table(pid);
+                    unset_pid_table(pid);       /* to be safe */
                     return(pid);
                 }
             }