]> granicus.if.org Git - apache/commitdiff
downgrade the log level of a proc_mutex_unlock error message
authorJeff Trawick <trawick@apache.org>
Tue, 31 May 2005 23:57:41 +0000 (23:57 +0000)
committerJeff Trawick <trawick@apache.org>
Tue, 31 May 2005 23:57:41 +0000 (23:57 +0000)
when it occurs during restart; it isn't at all uncommon then
when SysV semaphores are used for the accept mutex

same logic already in place for two other mutex calls

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

server/mpm/worker/worker.c

index 0a171365b6fa393504b2a1d2197829f7bc67811b..1380ee23b523ecb8f330f5ab6d2684d57eb4a07b 100644 (file)
@@ -760,7 +760,13 @@ static void *listener_thread(apr_thread_t *thd, void * dummy)
         else {
             if ((rv = SAFE_ACCEPT(apr_proc_mutex_unlock(accept_mutex)))
                 != APR_SUCCESS) {
-                ap_log_error(APLOG_MARK, APLOG_EMERG, rv, ap_server_conf,
+                int level = APLOG_EMERG;
+
+                if (ap_scoreboard_image->parent[process_slot].generation != 
+                    ap_scoreboard_image->global->running_generation) {
+                    level = APLOG_DEBUG; /* common to get these at restart time */
+                }
+                ap_log_error(APLOG_MARK, level, rv, ap_server_conf,
                              "apr_proc_mutex_unlock failed. Attempting to "
                              "shutdown process gracefully.");
                 signal_threads(ST_GRACEFUL);