[Spice-commits] gtk/channel-base.c
Yonit Halperin
yhalperi at kemper.freedesktop.org
Tue Apr 9 06:00:17 PDT 2013
gtk/channel-base.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
New commits:
commit db0a525588970859b67cf44c071c849b638f6eec
Author: Yonit Halperin <yhalperi at redhat.com>
Date: Mon Apr 8 16:27:11 2013 -0400
channel_base: exit handle_migrate when expecting MIGRATE_DATA and receiving something else
Previously, when an error occurred on the src server side, and we
received other message than MIGRATE_DATA, this messages was forwarded
to the dest server, and made it crash.
diff --git a/gtk/channel-base.c b/gtk/channel-base.c
index a7e9580..dff3024 100644
--- a/gtk/channel-base.c
+++ b/gtk/channel-base.c
@@ -168,11 +168,13 @@ void spice_channel_handle_migrate(SpiceChannel *channel, SpiceMsgIn *in)
if (mig->flags & SPICE_MIGRATE_NEED_DATA_TRANSFER) {
spice_channel_recv_msg(channel, get_msg_handler, &data);
if (!data) {
- g_warning("expected SPICE_MSG_MIGRATE_DATA, got empty message");
+ g_critical("expected SPICE_MSG_MIGRATE_DATA, got empty message");
+ return;
} else if (spice_header_get_msg_type(data->header, c->use_mini_header) !=
SPICE_MSG_MIGRATE_DATA) {
- g_warning("expected SPICE_MSG_MIGRATE_DATA, got %d",
+ g_critical("expected SPICE_MSG_MIGRATE_DATA, got %d",
spice_header_get_msg_type(data->header, c->use_mini_header));
+ return;
}
}
More information about the Spice-commits
mailing list