]> git.ipfire.org Git - thirdparty/openldap.git/commitdiff
More logging improvements
authorOndřej Kuzník <ondra@mistotebe.net>
Mon, 3 Jul 2017 15:37:35 +0000 (16:37 +0100)
committerOndřej Kuzník <okuznik@symas.com>
Tue, 17 Nov 2020 17:55:46 +0000 (17:55 +0000)
servers/lloadd/bind.c
servers/lloadd/client.c
servers/lloadd/operation.c

index 088ec3e24ca2c2351a5db207391b38b69e3de745..393989f76c2fa8c98be4d061723d3182e4972695 100644 (file)
@@ -118,6 +118,9 @@ fail:
         ber_free( copy, 0 );
     }
     ldap_pvt_thread_mutex_unlock( &upstream->c_io_mutex );
+    Debug( LDAP_DEBUG_STATS, "request_bind: "
+            "connid=%lu bind request processing failed, closing\n",
+            client->c_connid );
     return 1;
 }
 
@@ -248,6 +251,9 @@ fail:
         ber_free( copy, 0 );
     }
     ldap_pvt_thread_mutex_unlock( &upstream->c_io_mutex );
+    Debug( LDAP_DEBUG_STATS, "request_bind_as_vc: "
+            "connid=%lu bind request processing failed, closing\n",
+            client->c_connid );
     operation_send_reject( op, result, msg, 1 );
     return 1;
 }
index 5c589a3020176af16dd6a5a08ae10f3832610bbe..89af15a13835ba2638073278bdaa5ff5e84e814f 100644 (file)
@@ -55,7 +55,8 @@ client_read_cb( evutil_socket_t s, short what, void *arg )
     ber = c->c_currentber;
     if ( ber == NULL && (ber = ber_alloc()) == NULL ) {
         Debug( LDAP_DEBUG_ANY, "client_read_cb: "
-                "ber_alloc failed\n" );
+                "connid=%lu, ber_alloc failed\n",
+                c->c_connid );
         CLIENT_DESTROY(c);
         return;
     }
@@ -151,7 +152,8 @@ handle_requests( void *ctx, void *arg )
 
         if ( (ber = ber_alloc()) == NULL ) {
             Debug( LDAP_DEBUG_ANY, "client_read_cb: "
-                    "ber_alloc failed\n" );
+                    "connid=%lu, ber_alloc failed\n",
+                    c->c_connid );
             CLIENT_DESTROY(c);
             return NULL;
         }
@@ -205,7 +207,8 @@ handle_one_request( Connection *c )
     op = operation_init( c, ber );
     if ( !op ) {
         Debug( LDAP_DEBUG_ANY, "handle_one_request: "
-                "operation_init failed\n" );
+                "connid=%lu, operation_init failed\n",
+                c->c_connid );
         CLIENT_DESTROY(c);
         ber_free( ber, 1 );
         return -1;
index 14bd2e23cf3bf1f78da6922f6962db53a5caf764..bfaaaa5a39c1247fc927c8aff0bdd22e62521545 100644 (file)
@@ -628,6 +628,9 @@ operation_send_reject(
     ber = c->c_pendingber;
     if ( ber == NULL && (ber = ber_alloc()) == NULL ) {
         ldap_pvt_thread_mutex_unlock( &c->c_io_mutex );
+        Debug( LDAP_DEBUG_ANY, "operation_send_reject: "
+                "ber_alloc failed, closing connid=%lu\n",
+                c->c_connid );
         CONNECTION_LOCK_DECREF(c);
         operation_destroy_from_client( op );
         CLIENT_DESTROY(c);