]> git.0d.be Git - empathy.git/commitdiff
Fix broken logic that caused delivery report spinner to spin forever
authorDanielle Madeley <danielle.madeley@collabora.co.uk>
Tue, 3 May 2011 23:58:18 +0000 (09:58 +1000)
committerDanielle Madeley <danielle.madeley@collabora.co.uk>
Thu, 5 May 2011 07:31:19 +0000 (17:31 +1000)
libempathy/empathy-tp-chat.c

index 18087580bd31c04adb1c3c01ee47b9d04c00818a..72c6bebf06271433d45f72798b3e6b5c0ee67284 100644 (file)
@@ -101,13 +101,14 @@ tp_chat_set_delivery_status (EmpathyTpChat         *self,
                             EmpathyDeliveryStatus  delivery_status)
 {
        EmpathyTpChatPriv *priv = GET_PRIV (self);
+       TpDeliveryReportingSupportFlags flags =
+               tp_text_channel_get_delivery_reporting_support (
+                       TP_TEXT_CHANNEL (priv->channel));
 
        /* channel must support receiving failures and successes */
        if (!tp_str_empty (token) &&
-           tp_text_channel_get_delivery_reporting_support (
-               TP_TEXT_CHANNEL (priv->channel)) &
-               (TP_DELIVERY_REPORTING_SUPPORT_FLAG_RECEIVE_FAILURES |
-                TP_DELIVERY_REPORTING_SUPPORT_FLAG_RECEIVE_SUCCESSES)) {
+           flags & TP_DELIVERY_REPORTING_SUPPORT_FLAG_RECEIVE_FAILURES &&
+           flags & TP_DELIVERY_REPORTING_SUPPORT_FLAG_RECEIVE_SUCCESSES) {
 
                DEBUG ("Delivery status (%s) = %u", token, delivery_status);