]> granicus.if.org Git - apache/commitdiff
Log whether or not the restore from shm actually
authorJim Jagielski <jim@apache.org>
Wed, 19 Sep 2012 14:18:19 +0000 (14:18 +0000)
committerJim Jagielski <jim@apache.org>
Wed, 19 Sep 2012 14:18:19 +0000 (14:18 +0000)
resulted in a match of shm data, or whether it
was stale.

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

docs/log-message-tags/next-number
modules/proxy/proxy_util.c

index fd75012648ec57862e0c7980f0ed4f3ca1214f6c..978e2eca86db4d021eb216eacab725637ffe8c51 100644 (file)
@@ -1 +1 @@
-2337
+2339
index 48e60da4a25211b8dd1bdd65dbc31745f713348c..ce81b19e3bf4b5fafceb51c8e8034963a0f834e4 100644 (file)
@@ -1199,6 +1199,7 @@ PROXY_DECLARE(apr_status_t) ap_proxy_share_balancer(proxy_balancer *balancer,
 {
     apr_status_t rv = APR_SUCCESS;
     proxy_balancer_method *lbmethod;
+    char *ptr = "";
     if (!shm || !balancer->s)
         return APR_EINVAL;
 
@@ -1207,7 +1208,11 @@ PROXY_DECLARE(apr_status_t) ap_proxy_share_balancer(proxy_balancer *balancer,
         memcpy(shm, balancer->s, sizeof(proxy_balancer_shared));
         if (balancer->s->was_malloced)
             free(balancer->s);
+    } else {
+        ptr = "not ";
     }
+    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf, APLOGNO(02337)
+                 "%scopying shm for %s", ptr, balancer->s->name);
     balancer->s = shm;
     balancer->s->index = i;
     /* the below should always succeed */
@@ -1641,6 +1646,7 @@ PROXY_DECLARE(char *) ap_proxy_define_worker(apr_pool_t *p,
 PROXY_DECLARE(apr_status_t) ap_proxy_share_worker(proxy_worker *worker, proxy_worker_shared *shm,
                                                   int i)
 {
+    char *ptr = "";
     if (!shm || !worker->s)
         return APR_EINVAL;
 
@@ -1649,7 +1655,11 @@ PROXY_DECLARE(apr_status_t) ap_proxy_share_worker(proxy_worker *worker, proxy_wo
         memcpy(shm, worker->s, sizeof(proxy_worker_shared));
         if (worker->s->was_malloced)
             free(worker->s); /* was malloced in ap_proxy_define_worker */
+    } else {
+        ptr = "not ";
     }
+    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf, APLOGNO(02338)
+                 "%scopying shm for worker: %s", ptr, worker->s->name);
 
     worker->s = shm;
     worker->s->index = i;