Minor code simplification in util.c

darcs-hash:20070324193801-ac50b-e45d88fd7de0204467a0f7d52b71ee323f4e3f0d.gz
This commit is contained in:
axel 2007-03-25 05:38:01 +10:00
parent 94a483d46b
commit 65d99117aa

10
util.c
View file

@ -1358,17 +1358,11 @@ int b_append( buffer_t *b, const void *d, ssize_t len )
return 0;
}
if( len < 0 )
{
return 0;
}
if( b->length <= (b->used + len) )
{
size_t l = maxi( b->length*2,
maxi( b->used+len+MIN_SIZE,MIN_SIZE));
b->used+len+MIN_SIZE );
void *d = realloc( b->buff, l );
if( !d )
{