mirror of
https://git.gnunet.org/libmicrohttpd.git
synced 2026-09-25 04:09:31 +03:00
memorypool: removed redundant check, which also fails in case shrinking
This commit is contained in:
@@ -277,8 +277,7 @@ MHD_pool_reallocate (struct MemoryPool *pool,
|
||||
if (pool->pos == ROUND_TO_ALIGN (old_offset + old_size))
|
||||
{ /* "old" block is the last allocated block */
|
||||
const size_t new_apos = ROUND_TO_ALIGN (old_offset + new_size);
|
||||
if ( (new_apos > pool->end) ||
|
||||
(new_apos < pool->pos) ) /* Value wrap */
|
||||
if (new_apos > pool->end)
|
||||
return NULL; /* No space */
|
||||
|
||||
pool->pos = new_apos;
|
||||
|
||||
Reference in New Issue
Block a user