/* get (locked) connection */
c = connection_get( s );
- if ( !c ) return;
-
assert( c->c_conn_state == SLAP_C_CLIENT );
c->c_listener = NULL;
c = connection_get( s );
if ( c ) {
- connection_closing( c, "connection lost" );
- connection_close( c );
- connection_return( c );
+ if ( c->c_conn_state == SLAP_C_CLIENT ) {
+ connection_return( c );
+ connection_read_activate( s );
+ } else {
+ connection_closing( c, "connection lost" );
+ connection_close( c );
+ connection_return( c );
+ }
}
}