]> git.proxmox.com Git - mirror_qemu.git/commit - migration/migration.c
migration: Add migration_incoming_transport_cleanup()
authorPeter Xu <peterx@redhat.com>
Tue, 1 Mar 2022 08:39:14 +0000 (16:39 +0800)
committerDr. David Alan Gilbert <dgilbert@redhat.com>
Wed, 2 Mar 2022 18:20:45 +0000 (18:20 +0000)
commite031149c78489413038e934eec9f54ac699cf322
treeb6314db603a6fdf723c8177d6049b71e05c8c83c
parent27dd21b461569f3b85a9db409f9117ae9d976548
migration: Add migration_incoming_transport_cleanup()

Add a helper to cleanup the transport listener.

When do it, we should also null-ify the cleanup hook and the data, then it's
even safe to call it multiple times.

Move the socket_address_list cleanup altogether, because that's a mirror of the
listener channels and only for the purpose of query-migrate.  Hence when
someone wants to cleanup the listener transport, it should also want to cleanup
the socket list too, always.

No functional change intended.

Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Signed-off-by: Peter Xu <peterx@redhat.com>
Message-Id: <20220301083925.33483-15-peterx@redhat.com>
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
migration/migration.c
migration/migration.h