]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
Properly null-terminate the tpf_server_name string (in TPF-only code).
authorDavid McCreedy <mccreedy@apache.org>
Thu, 31 May 2007 04:26:54 +0000 (04:26 +0000)
committerDavid McCreedy <mccreedy@apache.org>
Thu, 31 May 2007 04:26:54 +0000 (04:26 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/1.3.x@543050 13f79535-47bb-0310-9956-ffa450edef68

src/main/http_main.c

index 961c5a828ebebab0f91a7d76c7a233bb413b7179..f063f76e91cce4e850cde62f6bc9c412f74a2444 100644 (file)
@@ -5687,7 +5687,7 @@ int REALMAIN(int argc, char *argv[])
     if (!tpf_child) {
         memcpy(tpf_server_name, input_parms.parent.servname,
                INETD_SERVNAME_LENGTH);
-        tpf_server_name[INETD_SERVNAME_LENGTH + 1] = '\0';
+        tpf_server_name[INETD_SERVNAME_LENGTH] = '\0';
         sprintf(tpf_mutex_key, "%.*x", (int) TPF_MUTEX_KEY_SIZE - 1, getpid());
         tpf_parent_pid = getppid();
         ap_open_logs(server_conf, plog);