Backout premature commit.

This commit is contained in:
Kurt Zeilenga 1999-11-08 19:36:30 +00:00
parent 23cb3a0555
commit 5f3ec33b0c

View File

@ -135,21 +135,23 @@ ber_peek_tag(
BerElement *ber_in,
ber_len_t *len )
{
char* save;
ber_tag_t tag;
BerElement *ber;
ber_tag_t tag;
assert( ber_in != NULL );
assert( BER_VALID( ber_in ) );
/* save state */
save = ber->ber_ptr;
ber = ber_dup( ber_in );
if( ber == NULL ) {
return LBER_ERROR;
}
assert( BER_VALID( ber ) );
tag = ber_skip_tag( ber, len );
/* restore state */
ber->ber_ptr = save;
ber_free( ber, 0 );
return( tag );
}
@ -451,7 +453,8 @@ ber_first_element(
/* skip the sequence header, use the len to mark where to stop */
if ( ber_skip_tag( ber, len ) == LBER_DEFAULT ) {
return( LBER_ERROR );
*last = NULL;
return( LBER_DEFAULT );
}
*last = ber->ber_ptr + *len;
@ -476,7 +479,6 @@ ber_next_element(
assert( BER_VALID( ber ) );
if ( ber->ber_ptr == last ) {
/* set last to NULL on end of SEQUENCE */
return( LBER_DEFAULT );
}