/* * meta_clear_unused_candidates * * clears all candidates except candidate */ int meta_clear_unused_candidates( Operation *op, int candidate ) { metainfo_t *mi = ( metainfo_t * )op->o_bd->be_private; int i; SlapReply *candidates = meta_back_candidates_get( op ); for ( i = 0; i < mi->mi_ntargets; ++i ) { if ( i == candidate ) { continue; } META_CANDIDATE_RESET( &candidates[ i ] ); } return 0; }
/* * asyncmeta_clear_unused_candidates * * clears all candidates except candidate */ int asyncmeta_clear_unused_candidates( Operation *op, int candidate, a_metaconn_t *mc, SlapReply *candidates) { a_metainfo_t *mi = mc->mc_info; int i; for ( i = 0; i < mi->mi_ntargets; ++i ) { if ( i == candidate ) { continue; } META_CANDIDATE_RESET( &candidates[ i ] ); } return 0; }