[geary/wip/765516-gtk-widget-conversation-viewer: 168/187] Fix a possible crit error when cancelling conversation load.



commit 707fe03270f35b06be6b302523b0d2a3f5ee7804
Author: Michael James Gratton <mike vee net>
Date:   Mon Sep 12 15:05:32 2016 +1000

    Fix a possible crit error when cancelling conversation load.

 .../conversation-viewer/conversation-email.vala    |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/src/client/conversation-viewer/conversation-email.vala 
b/src/client/conversation-viewer/conversation-email.vala
index 35ccab0..12e2f05 100644
--- a/src/client/conversation-viewer/conversation-email.vala
+++ b/src/client/conversation-viewer/conversation-email.vala
@@ -675,6 +675,9 @@ public class ConversationEmail : Gtk.Box {
             }
 
             foreach (Geary.Attachment attachment in this.displayed_attachments) {
+                if (load_cancelled.is_cancelled()) {
+                    return;
+                }
                 AttachmentView view = new AttachmentView(attachment);
                 this.attachments_view.add(view);
                 yield view.load_icon(load_cancelled);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]