diff options
Diffstat (limited to 'src/microhttpd/memorypool.c')
-rw-r--r-- | src/microhttpd/memorypool.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/microhttpd/memorypool.c b/src/microhttpd/memorypool.c index a979c64a..27f7f5ab 100644 --- a/src/microhttpd/memorypool.c +++ b/src/microhttpd/memorypool.c | |||
@@ -324,7 +324,8 @@ MHD_pool_reallocate (struct MemoryPool *pool, | |||
324 | mhd_assert (old == NULL || pool->memory + pool->size >= (uint8_t*) old | 324 | mhd_assert (old == NULL || pool->memory + pool->size >= (uint8_t*) old |
325 | + old_size); | 325 | + old_size); |
326 | /* Blocks "from the end" must not be reallocated */ | 326 | /* Blocks "from the end" must not be reallocated */ |
327 | mhd_assert (old == NULL || pool->memory + pool->pos > (uint8_t*) old); | 327 | mhd_assert (old == NULL || old_size == 0 || \ |
328 | pool->memory + pool->pos > (uint8_t*) old); | ||
328 | 329 | ||
329 | if (0 != old_size) | 330 | if (0 != old_size) |
330 | { /* Need to save some data */ | 331 | { /* Need to save some data */ |