> > From: Victor Toso <me@xxxxxxxxxxxxxx> > > In the host, it is possible that the migration goes faster than > client side would expect. In case we receive a migrate-begin message > followed by switch-host message, we should be sure to abort previous Aren't these message exclusives? Is there a bug in the server? > migration to avoid keeping some unused objects in memory plus > critical messages in subsequent migrations as below: > > > GSpice-CRITICAL **: spice_session_set_migration_session: > > assertion 'session->priv->migration == NULL' failed > > Found by testing with spice/tests/migraton.py without QCOW image. > Do you mean tests/migrate.py ? I don't have spice/tests/migraton.py (not even spice/tests/migration.py) > Signed-off-by: Victor Toso <victortoso@xxxxxxxxxx> > --- > src/channel-main.c | 5 +++++ > 1 file changed, 5 insertions(+) > > diff --git a/src/channel-main.c b/src/channel-main.c > index 4305dcd..4afaa3f 100644 > --- a/src/channel-main.c > +++ b/src/channel-main.c > @@ -2506,6 +2506,11 @@ static void > main_handle_migrate_switch_host(SpiceChannel *channel, SpiceMsgIn *i > } > > session = spice_channel_get_session(channel); > + /* It is possible that we were migrating before receiving the > switch-host > + * message without receiving a migrate-cancel message. Simply cancel > + * previous migration before switching host */ > + spice_session_abort_migration(session); > + > spice_session_set_migration_state(session, > SPICE_SESSION_MIGRATION_SWITCHING); > g_object_set(session, > "host", host, Patch seems fine. Is the migration seamless or not? Frediano _______________________________________________ Spice-devel mailing list Spice-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/spice-devel