From: Howard Chu Date: Wed, 24 Apr 2013 07:27:26 +0000 (-0700) Subject: Don't expire a conn if it's still referenced X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=9381d04b8748b4917ffb175c187ccf8b77e75743;p=openldap Don't expire a conn if it's still referenced --- diff --git a/servers/slapd/back-meta/conn.c b/servers/slapd/back-meta/conn.c index e428977055..da8e0a13e3 100644 --- a/servers/slapd/back-meta/conn.c +++ b/servers/slapd/back-meta/conn.c @@ -1180,8 +1180,8 @@ retry_lock:; mc = NULL; } else { - if ( ( mi->mi_conn_ttl != 0 && op->o_time > mc->mc_create_time + mi->mi_conn_ttl ) - || ( mi->mi_idle_timeout != 0 && op->o_time > mc->mc_time + mi->mi_idle_timeout ) ) + if ( mc->mc_refcnt == 0 && (( mi->mi_conn_ttl != 0 && op->o_time > mc->mc_create_time + mi->mi_conn_ttl ) + || ( mi->mi_idle_timeout != 0 && op->o_time > mc->mc_time + mi->mi_idle_timeout )) ) { #if META_BACK_PRINT_CONNTREE > 0 meta_back_print_conntree( mi,