aboutsummaryrefslogtreecommitdiff
path: root/migration/migration.c
diff options
context:
space:
mode:
authorDr. David Alan Gilbert <dgilbert@redhat.com>2015-05-21 13:24:16 +0100
committerJuan Quintela <quintela@redhat.com>2015-06-12 06:54:01 +0200
commit1a8f46f8d61ef885ff9d0bda251e4e9830c932ef (patch)
tree1d6b67fab89c55ea450dc1811aef2194fab60743 /migration/migration.c
parent7c1e52ba6f3994dc127118f491258ce84d0beb52 (diff)
Move loadvm_handlers into MigrationIncomingState
In postcopy we need the loadvm_handlers to be used in a couple of different instances of the loadvm loop/routine, and thus it can't be local any more. Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Reviewed-by: Juan Quintela <quintela@redhat.com> Signed-off-by: Juan Quintela <quintela@redhat.com>
Diffstat (limited to 'migration/migration.c')
-rw-r--r--migration/migration.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/migration/migration.c b/migration/migration.c
index 66c0b57b26..b04b4571a8 100644
--- a/migration/migration.c
+++ b/migration/migration.c
@@ -84,12 +84,14 @@ MigrationIncomingState *migration_incoming_state_new(QEMUFile* f)
{
mis_current = g_malloc0(sizeof(MigrationIncomingState));
mis_current->file = f;
+ QLIST_INIT(&mis_current->loadvm_handlers);
return mis_current;
}
void migration_incoming_state_destroy(void)
{
+ loadvm_free_handlers(mis_current);
g_free(mis_current);
mis_current = NULL;
}