mirror of
https://github.com/izzy2lost/xemu.git
synced 2026-07-06 00:20:22 -07:00
migration: fix leak of src file on dst
The return path channel is possibly leaked. Fix it. Signed-off-by: Peter Xu <peterx@redhat.com> Reviewed-by: Juan Quintela <quintela@redhat.com> Signed-off-by: Juan Quintela <quintela@redhat.com>
This commit is contained in:
@@ -133,6 +133,11 @@ void migration_incoming_state_destroy(void)
|
||||
{
|
||||
struct MigrationIncomingState *mis = migration_incoming_get_current();
|
||||
|
||||
if (mis->to_src_file) {
|
||||
qemu_fclose(mis->to_src_file);
|
||||
mis->to_src_file = NULL;
|
||||
}
|
||||
|
||||
qemu_event_destroy(&mis->main_thread_load_event);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user