From eab5b9570a5205c7dee8e4de876c95c1fe8e3e95 Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Mon, 13 Jul 2009 15:15:27 +0000 Subject: [PATCH] Fix result when no VLV match --- servers/slapd/overlays/sssvlv.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/servers/slapd/overlays/sssvlv.c b/servers/slapd/overlays/sssvlv.c index 7f16ac7cf3..707f6820ea 100644 --- a/servers/slapd/overlays/sssvlv.c +++ b/servers/slapd/overlays/sssvlv.c @@ -427,7 +427,10 @@ range_err: for (i=1; isc_nkeys; i++) { BER_BVZERO( &sn->sn_vals[i] ); } - cur_node = tavl_find2( so->so_tree, sn, node_cmp ); + cur_node = tavl_find3( so->so_tree, sn, node_cmp, &j ); + /* didn't find >= match */ + if ( j > 0 ) + cur_node = NULL; op->o_tmpfree( sn, op->o_tmpmemctx ); if ( !cur_node ) { -- 2.39.5