Changes with Apache 2.3.9
+ *) mod_cgid: Log a warning if the ScriptSock path is truncated because
+ it is too long. PR 49388. [Stefan Fritsch]
+
*) vhosts: Do not allow _default_ in NameVirtualHost, or mixing *
and non-* ports on NameVirtualHost, or multiple NameVirtualHost
directives for the same address:port, or NameVirtualHost
}
if (!first_time) {
+ char *tmp_sockname;
total_modules = 0;
for (m = ap_preloaded_modules; *m != NULL; m++)
total_modules++;
parent_pid = getpid();
- sockname = ap_server_root_relative(p, sockname);
+ tmp_sockname = ap_server_root_relative(p, sockname);
+ if (strlen(tmp_sockname) > sizeof(server_addr->sun_path) - 1) {
+ tmp_sockname[sizeof(server_addr->sun_path)] = '\0';
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, main_server,
+ "The length of the ScriptSock path exceeds maximum, "
+ "truncating to %s", tmp_sockname);
+ }
+ sockname = tmp_sockname;
server_addr_len = APR_OFFSETOF(struct sockaddr_un, sun_path) + strlen(sockname);
server_addr = (struct sockaddr_un *)apr_palloc(p, server_addr_len + 1);