mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-24 00:29:35 -05:00
improve previous commit
This commit is contained in:
parent
8b76e15d28
commit
8f1c5c4df5
1 changed files with 2 additions and 1 deletions
|
|
@ -700,8 +700,9 @@ struct berval *
|
|||
ber_bvreplace_x( struct berval *dst, LDAP_CONST struct berval *src, void *ctx )
|
||||
{
|
||||
assert( dst != NULL );
|
||||
assert( !BER_BVISNULL( src ) );
|
||||
|
||||
if ( dst->bv_len == 0 || dst->bv_len < src->bv_len ) {
|
||||
if ( BER_BVISNULL( dst ) || dst->bv_len < src->bv_len ) {
|
||||
dst->bv_val = ber_memrealloc_x( dst->bv_val, src->bv_len + 1, ctx );
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue