qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [RFC][PATCH 03/12] Make sure to release allocated stack whe


From: Stefan Hajnoczi
Subject: [Qemu-devel] [RFC][PATCH 03/12] Make sure to release allocated stack when coroutine is released.
Date: Sat, 22 Jan 2011 09:29:18 +0000

Copied from a fix to the original code by Anthony Liguori
<address@hidden>.

Signed-off-by: Stefan Hajnoczi <address@hidden>
---
 coroutine_ucontext.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/coroutine_ucontext.c b/coroutine_ucontext.c
index 25e8687..f76da94 100644
--- a/coroutine_ucontext.c
+++ b/coroutine_ucontext.c
@@ -38,6 +38,7 @@ static int _coroutine_release(struct continuation *cc)
                if (ret < 0)
                        return ret;
        }
+    munmap(co->cc.stack, co->cc.stack_size);
 
        co->caller = NULL;
 
-- 
1.7.2.3




reply via email to

[Prev in Thread] Current Thread [Next in Thread]