From 19a0d8293721af7d334a2e925c4121c366d3e740 Mon Sep 17 00:00:00 2001 From: Hallvard Furuseth Date: Sun, 2 Apr 2006 23:49:57 +0000 Subject: [PATCH] Init & destroy so.s_mutex around syncprov_findbase() call in syncprov_op_search --- servers/slapd/overlays/syncprov.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/servers/slapd/overlays/syncprov.c b/servers/slapd/overlays/syncprov.c index 916b2a2ae3..2278ad34eb 100644 --- a/servers/slapd/overlays/syncprov.c +++ b/servers/slapd/overlays/syncprov.c @@ -1902,10 +1902,12 @@ syncprov_op_search( Operation *op, SlapReply *rs ) /* syncprov_findbase expects to be called as a callback... */ sc.sc_private = &opc; opc.son = on; + ldap_pvt_thread_mutex_init( &so.s_mutex ); cb = op->o_callback; op->o_callback = ≻ rs->sr_err = syncprov_findbase( op, &fc ); op->o_callback = cb; + ldap_pvt_thread_mutex_destroy( &so.s_mutex ); if ( rs->sr_err != LDAP_SUCCESS ) { send_ldap_result( op, rs );