aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOrit Wasserman <owasserm@redhat.com>2014-01-30 20:08:33 +0200
committerJuan Quintela <quintela@redhat.com>2014-02-04 16:48:49 +0100
commitf6c6483b259a2395ee44cfa966f622e0f2dbe2ae (patch)
treef7db6539de8c5d1c4971c7781480ae0fc99688cb
parentf9ee9f9ac28d6964772c08d5d428b713d58a3aca (diff)
Set xbzrle buffers to NULL after freeing them to avoid double free errors
Signed-off-by: Orit Wasserman <owasserm@redhat.com> Reviewed-by: Juan Quintela <quintela@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Juan Quintela <quintela@redhat.com>
-rw-r--r--arch_init.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/arch_init.c b/arch_init.c
index 77912e7a7d..66f5e82263 100644
--- a/arch_init.c
+++ b/arch_init.c
@@ -617,6 +617,9 @@ static void migration_end(void)
g_free(XBZRLE.current_buf);
g_free(XBZRLE.decoded_buf);
XBZRLE.cache = NULL;
+ XBZRLE.encoded_buf = NULL;
+ XBZRLE.current_buf = NULL;
+ XBZRLE.decoded_buf = NULL;
}
}