From: Pavel Charvat Date: Mon, 5 Dec 2011 10:21:42 +0000 (+0100) Subject: mempool: Fixed a memory leak in mp_pop(). X-Git-Tag: v5.0~100 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=5204e761fb408776d1e4f0b01f0bad19f2d07e10;p=libucw.git mempool: Fixed a memory leak in mp_pop(). --- diff --git a/ucw/mempool.c b/ucw/mempool.c index d04e15ef..f776caaa 100644 --- a/ucw/mempool.c +++ b/ucw/mempool.c @@ -344,8 +344,7 @@ void mp_pop(struct mempool *pool) { ASSERT(pool->state.next); - struct mempool_state state = pool->state; - mp_restore(pool, &state); + mp_restore(pool, pool->state.next); } #ifdef TEST