From 452fc403dda0731bb71d13b0f76f25b6fd7f362b Mon Sep 17 00:00:00 2001 From: Sang Seok Lim Date: Fri, 17 Sep 2004 16:49:38 +0000 Subject: [PATCH] Bug Fix : removing problematic counter increment --- servers/slapd/component.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/servers/slapd/component.c b/servers/slapd/component.c index 0a0b22f17e..75920a06e3 100644 --- a/servers/slapd/component.c +++ b/servers/slapd/component.c @@ -95,11 +95,8 @@ get_comp_filter ( Operation* op, struct berval* bv, ComponentFilter** filt, static void eat_whsp( ComponentAssertionValue* cav ) { - int count = 0; - for ( ; ; ) { - if ( cav->cav_ptr[count++] == ' ' ) cav->cav_ptr++; - else break; - } + while ( ( cav->cav_ptr <= cav->cav_end ) && ( *cav->cav_ptr == ' ' ) ) + cav->cav_ptr++; } static int -- 2.39.5