From f20a6a27b375dbbd0af77c8b4e4016f8b9526000 Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Mon, 25 Mar 2002 11:52:39 +0000 Subject: [PATCH] Fix ITS#1675, make sure search results are initialized --- servers/slapd/backglue.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/servers/slapd/backglue.c b/servers/slapd/backglue.c index 4b0b49000f..63dd4158ad 100644 --- a/servers/slapd/backglue.c +++ b/servers/slapd/backglue.c @@ -327,6 +327,7 @@ glue_back_search ( case LDAP_SCOPE_ONELEVEL: case LDAP_SCOPE_SUBTREE: op->o_callback = &cb; + rc = gs.err = LDAP_UNWILLING_TO_PERFORM; /* * Execute in reverse order, most general first @@ -336,13 +337,17 @@ glue_back_search ( continue; if (tlimit) { t2limit = stoptime - slap_get_time (); - if (t2limit <= 0) + if (t2limit <= 0) { + rc = gs.err = LDAP_TIMELIMIT_EXCEEDED; break; + } } if (slimit) { s2limit = slimit - gs.nentries; - if (s2limit <= 0) + if (s2limit <= 0) { + rc = gs.err = LDAP_SIZELIMIT_EXCEEDED; break; + } } /* * check for abandon -- 2.39.5