summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVivek Dasmohapatra <vivek@collabora.co.uk>2011-04-01 14:35:26 +0100
committerVivek Dasmohapatra <vivek@collabora.co.uk>2011-04-05 14:19:11 +0100
commit6060526c748a8829444e1d108dc6547b6c4622e7 (patch)
treea6563aa7272886e7dd7e8302c90fdddd21466ead
parent46fd73820ee21652c815205d6e3d6f6538c538b6 (diff)
downloadtelepathy-mission-control-6060526c748a8829444e1d108dc6547b6c4622e7.tar.gz
Restart request if the channel owner closed it before we could send our message
-rw-r--r--src/mcd-dispatcher.c15
1 files changed, 6 insertions, 9 deletions
diff --git a/src/mcd-dispatcher.c b/src/mcd-dispatcher.c
index c3087adb..fa9f5033 100644
--- a/src/mcd-dispatcher.c
+++ b/src/mcd-dispatcher.c
@@ -2218,6 +2218,9 @@ send_message_submitted (TpChannel *proxy,
_mcd_channel_close (channel);
}
+static void messages_send_message_start (DBusGMethodInvocation *context,
+ MessageContext *message);
+
static void
send_message_got_channel (McdRequest *request,
McdChannel *channel,
@@ -2248,15 +2251,9 @@ send_message_got_channel (McdRequest *request,
{
if (message->tries++ == 0)
{
- /* FIXME: the intention is to keep the account blocked and *
- * retry the transmission here: no tim eto implement this *
- * for the first draft but we'll get to it shortly. */
- GError *error = g_error_new_literal (TP_ERRORS, TP_ERROR_CANCELLED,
- "Channel closed by user");
-
- dbus_g_method_return_error (message->dbus_context, error);
- _mcd_request_unblock_account (account_path);
- g_error_free (error);
+ messages_send_message_start (message->dbus_context, message);
+ /* we created a new lock above, we can now release the old one: */
+ _mcd_request_unblock_account (message->account_path);
}
else
{