Signed-off-by: Dunrong Huang <riegamaths@xxxxxxxxx> --- gtk/channel-main.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/gtk/channel-main.c b/gtk/channel-main.c index b2253a6..95f46c2 100644 --- a/gtk/channel-main.c +++ b/gtk/channel-main.c @@ -2443,6 +2443,13 @@ static void file_xfer_send_start_msg(gpointer data, gpointer user_data) gboolean spice_main_file_xfer(SpiceMainChannel *channel, GList *files, GError *err) { + SpiceMainChannelPrivate *c = channel->priv; + + if (!c->agent_connected) { + SPICE_DEBUG("spice agent is not connected, file xfer is disable now"); + return FALSE; + } + /* Send VD_AGENT_FILE_XFER_START message to guest for every file */ g_list_foreach(files, file_xfer_send_start_msg, channel); g_list_free_full(files, g_free); -- 1.8.0 _______________________________________________ Spice-devel mailing list Spice-devel@xxxxxxxxxxxxxxxxxxxxx http://lists.freedesktop.org/mailman/listinfo/spice-devel