[Spice-devel] [PATCH spice-gtk V6 3/3] file-xfer: disable file-xfer when agent is not connected
riegamaths at gmail.com
riegamaths at gmail.com
Wed Jan 9 19:02:21 PST 2013
From: Dunrong Huang <riegamaths at gmail.com>
Signed-off-by: Dunrong Huang <riegamaths at gmail.com>
Signed-off-by: mathslinux <riegamaths at gmail.com>
---
gtk/channel-main.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/gtk/channel-main.c b/gtk/channel-main.c
index a3211e1..fad4215 100644
--- a/gtk/channel-main.c
+++ b/gtk/channel-main.c
@@ -2716,10 +2716,14 @@ void spice_main_file_copy_async(SpiceMainChannel *channel,
GAsyncReadyCallback callback,
gpointer user_data)
{
+ SpiceMainChannelPrivate *c = channel->priv;
+
g_return_if_fail(channel != NULL);
g_return_if_fail(SPICE_IS_MAIN_CHANNEL(channel));
g_return_if_fail(sources != NULL && sources[0] != NULL);
+ g_return_if_fail(c->agent_connected);
+
/* At the moment, the copy() method is limited to a single file,
support for copying multi-files will be implemented later. */
g_return_if_fail(sources[1] == NULL);
--
1.7.12.4
More information about the Spice-devel
mailing list