From: Kurt Zeilenga Date: Fri, 24 Sep 1999 02:30:33 +0000 (+0000) Subject: ITS#302 ldif fix. Treat value with only continuation markers X-Git-Tag: UCDATA_2_4~380 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=3a44abba1a963ae90a14960e52c69057aa73fc5c;p=openldap ITS#302 ldif fix. Treat value with only continuation markers as an empty value. Complain, of course, as this isn't valid LDIF. --- diff --git a/libraries/libldif/line64.c b/libraries/libldif/line64.c index f2a8e995ed..b02cf8f4b2 100644 --- a/libraries/libldif/line64.c +++ b/libraries/libldif/line64.c @@ -135,6 +135,13 @@ ldif_parse_line( s++; } + /* check for continued line markers that should be deleted */ + for ( p = s, d = s; *p; p++ ) { + if ( *p != CONTINUED_LINE_MARKER ) + *d++ = *p; + } + *d = '\0'; + /* if no value is present, error out */ if ( *s == '\0' ) { ber_pvt_log_printf( LDAP_DEBUG_PARSE, ldif_debug, @@ -145,13 +152,6 @@ ldif_parse_line( goto done; } - /* check for continued line markers that should be deleted */ - for ( p = s, d = s; *p; p++ ) { - if ( *p != CONTINUED_LINE_MARKER ) - *d++ = *p; - } - *d = '\0'; - if ( b64 ) { char *byte = s;