tag != LBER_DEFAULT && rc != LBER_DEFAULT;
tag = ber_next_element( ber, &len, last ) )
{
+ void *save = *sss;
+
*sss = (char **) LBER_REALLOC( *sss,
(j + 2) * sizeof(char *) );
+ if( *sss == NULL ) {
+ LBER_MEMFREE( save );
+ rc = LBER_DEFAULT;
+ goto breakout;
+ }
+
rc = ber_get_stringa( ber, &((*sss)[j]) );
j++;
}
tag != LBER_DEFAULT && rc != LBER_DEFAULT;
tag = ber_next_element( ber, &len, last ) )
{
+ void *save = *bv;
+
*bv = (struct berval **) LBER_REALLOC( *bv,
(j + 2) * sizeof(struct berval *) );
+ if( *bv == NULL ) {
+ LBER_MEMFREE( save );
+ rc = LBER_DEFAULT;
+ goto breakout;
+ }
+
rc = ber_get_stringal( ber, &((*bv)[j]) );
j++;
}
}
}
+breakout:
va_end( ap );
if ( rc == LBER_DEFAULT ) {