[geary/cherry-pick-99730af3] Merge branch 'mjog/766-search-deadlock' into 'mainline'
- From: Michael Gratton <mjog src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [geary/cherry-pick-99730af3] Merge branch 'mjog/766-search-deadlock' into 'mainline'
- Date: Sat, 4 Apr 2020 02:27:59 +0000 (UTC)
commit 9fa35a4442188f8471b026b721fbf6a7bbfcd7e9
Author: Michael Gratton <mike vee net>
Date: Sat Apr 4 02:27:12 2020 +0000
Merge branch 'mjog/766-search-deadlock' into 'mainline'
ConversationWebView: Avoid a deadlock cancelling search highlighting
Closes #766
See merge request GNOME/geary!486
(cherry picked from commit 99730af3cea7f2ba0dbe8aa33636672843a06e69)
ee2c66a3 ConversationWebView: Avoid a deadlock cancelling search highlighting
src/client/conversation-viewer/conversation-web-view.vala | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
---
diff --git a/src/client/conversation-viewer/conversation-web-view.vala
b/src/client/conversation-viewer/conversation-web-view.vala
index d22a836e..9832efa5 100644
--- a/src/client/conversation-viewer/conversation-web-view.vala
+++ b/src/client/conversation-viewer/conversation-web-view.vala
@@ -128,7 +128,10 @@ public class ConversationWebView : ClientWebView {
callback();
});
ulong cancelled_handler = cancellable.cancelled.connect(() => {
- callback();
+ // Do this at idle since per the docs for
+ // GLib.Cancellable.disconnect, disconnecting a
+ // handler from within a handler causes a deadlock.
+ GLib.Idle.add(() => callback());
});
controller.search(
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]