[Spice-commits] 2 commits - client/red_client.cpp common/backtrace.h
Arnon Gilboa
agilboa at kemper.freedesktop.org
Sun Jul 31 07:39:32 PDT 2011
client/red_client.cpp | 9 +++++++--
common/backtrace.h | 4 ++++
2 files changed, 11 insertions(+), 2 deletions(-)
New commits:
commit 759fe8e27027dd8d8882eca60c9ba50b7afb0ba9
Author: Christophe Fergeau <cfergeau at redhat.com>
Date: Fri Jul 29 17:31:01 2011 +0200
client: fix 30s timeout regression
Changelog from Arnon Gilboa, patch from me:
Commit eb6f55409412 caused the following regression:
When client runs without the auto-conf or disable-effects options
(either from CLI or controller), which is the case when using Spice
from Admin Portal, the client will unecessarily wait for 30sec before
connecting to a Windows guest with an agent running (this won't happen
with linux guests or without an agent running).
The mentioned patch assumed that on_agent_reply() of
VD_AGENT_DISPLAY_CONFIG will call send_main_attach_channels() and
connect. However, when auto-conf or disable-effects are not used,
on_agent_reply() will ignore the reply and not call
send_main_attach_channels(). Therefore, send_main_attach_channels()
will only be called on agent timeout.
The solution is to activate agent timer only if auto-conf or
disable-effects. Otherwise, simply call send_main_attach_channels().
Fixes rhbz #726441
diff --git a/client/red_client.cpp b/client/red_client.cpp
index a74fd10..d0e7a3f 100644
--- a/client/red_client.cpp
+++ b/client/red_client.cpp
@@ -971,9 +971,14 @@ void RedClient::handle_init(RedPeer::InMessage* message)
post_message(msg);
send_agent_announce_capabilities(true);
if (_auto_display_res) {
- send_agent_monitors_config();
+ send_agent_monitors_config();
+ }
+
+ if (_auto_display_res || !_display_setting.is_empty()) {
+ _application.activate_interval_timer(*_agent_timer, AGENT_TIMEOUT);
+ } else {
+ send_main_attach_channels();
}
- _application.activate_interval_timer(*_agent_timer, AGENT_TIMEOUT);
} else {
if (_auto_display_res || !_display_setting.is_empty()) {
LOG_WARN("no agent running, display options have been ignored");
commit 8b4ff62ddbef215859161d042012d705e64ea1bb
Author: Alon Levy <alevy at redhat.com>
Date: Wed Jul 20 16:19:51 2011 +0300
common/backtrace.h: disable for WIN32
This also catches mingw32 which is probably fine, but at least it fixes
the build on visual studio.
diff --git a/common/backtrace.h b/common/backtrace.h
index 3b0c132..21b6b67 100644
--- a/common/backtrace.h
+++ b/common/backtrace.h
@@ -19,6 +19,10 @@
#ifndef BACKTRACE_H
#define BACKTRACE_H
+#ifdef WIN32
+#define spice_backtrace()
+#else
void spice_backtrace(void);
+#endif
#endif // BACKTRACE_H
More information about the Spice-commits
mailing list