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>
This commit is contained in:
Orit Wasserman 2014-01-30 20:08:33 +02:00 committed by Juan Quintela
parent f9ee9f9ac2
commit f6c6483b25

View file

@ -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;
}
}