From 781c2d02a10fba57cd5e41683ef932c21d47bc9e Mon Sep 17 00:00:00 2001 From: Kurt Zeilenga Date: Mon, 26 Apr 2004 23:16:45 +0000 Subject: [PATCH] fix Compare bug in liblber/memory.c (ITS#3116) --- libraries/liblber/memory.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/liblber/memory.c b/libraries/liblber/memory.c index 2f53f470f7..18b5bac876 100644 --- a/libraries/liblber/memory.c +++ b/libraries/liblber/memory.c @@ -341,7 +341,7 @@ ber_memrealloc_x( void* p, ber_len_t s, void *ctx ) mh = p; mh->bm_length = s; setend( (char *)&mh[1] + mh->bm_length ); - if( (s - oldlen) > 0 ) { + if( s > oldlen ) { /* poison any new memory */ memset( (char *)&mh[1] + oldlen, 0xff, s - oldlen); } -- 2.39.5