summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2012-07-28 11:06:49 +0200
committerHans de Goede <hdegoede@redhat.com>2012-07-28 11:09:42 +0200
commit498cc2677dc75a9d868c748bea08a07f82ce9d3d (patch)
treea7ec321d2c76f58bf354803cf9225d8158e0dcb2
parent99b2144be5f6261705f7d9f5c112a9453bf2839d (diff)
channel-display: Set monitors_max to 1 on init
This fixes remote-viewer with the new multi monitor support not working when connecting to a spice-server without the new multi-monitor support. Before this fix remote-viewer would hit the following g_return_if_fail: (remote-viewer:24787): remote-viewer-CRITICAL **: virt_viewer_session_spice_display_monitors: assertion `monitors->len <= monitors_max' failed Signed-off-by: Hans de Goede <hdegoede@redhat.com>
-rw-r--r--gtk/channel-display.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/gtk/channel-display.c b/gtk/channel-display.c
index 72d2c12..4ed3bbb 100644
--- a/gtk/channel-display.c
+++ b/gtk/channel-display.c
@@ -696,6 +696,7 @@ static void spice_display_channel_init(SpiceDisplayChannel *channel)
#if defined(WIN32)
c->dc = create_compatible_dc();
#endif
+ c->monitors_max = 1;
spice_display_channel_reset_capabilities(SPICE_CHANNEL(channel));
}