From 2f1a2dd329b91afe561cd06b872d09630d4edb6a Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Wed, 4 Feb 2015 02:03:55 +0000 Subject: [PATCH] ITS#8046 fix vrFilter_free --- servers/slapd/filter.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/servers/slapd/filter.c b/servers/slapd/filter.c index b859f73..22c81c8 100644 --- a/servers/slapd/filter.c +++ b/servers/slapd/filter.c @@ -1158,14 +1158,10 @@ get_vrFilter( Operation *op, BerElement *ber, void vrFilter_free( Operation *op, ValuesReturnFilter *vrf ) { - ValuesReturnFilter *p, *next; + ValuesReturnFilter *next; - if ( vrf == NULL ) { - return; - } - - for ( p = vrf; p != NULL; p = next ) { - next = p->vrf_next; + for ( ; vrf != NULL; vrf = next ) { + next = vrf->vrf_next; switch ( vrf->vrf_choice & SLAPD_FILTER_MASK ) { case LDAP_FILTER_PRESENT: -- 1.7.10.4