| |
@@ -0,0 +1,43 @@
|
| |
+ # HG changeset patch
|
| |
+ # Node ID 45afca0be177
|
| |
+ # Parent f373c5662415
|
| |
+ diff --git a/pidgin/plugins/spellchk.c b/pidgin/plugins/spellchk.c
|
| |
+ --- a/pidgin/plugins/spellchk.c
|
| |
+ +++ b/pidgin/plugins/spellchk.c
|
| |
+ @@ -289,12 +289,14 @@
|
| |
+
|
| |
+ g_return_if_fail(spell != NULL);
|
| |
+
|
| |
+ - buffer = gtk_text_view_get_buffer(spell->view);
|
| |
+ + if (spell->view != NULL) {
|
| |
+ + buffer = gtk_text_view_get_buffer(spell->view);
|
| |
+
|
| |
+ - g_signal_handlers_disconnect_matched(buffer,
|
| |
+ - G_SIGNAL_MATCH_DATA,
|
| |
+ - 0, 0, NULL, NULL,
|
| |
+ - spell);
|
| |
+ + g_signal_handlers_disconnect_matched(buffer,
|
| |
+ + G_SIGNAL_MATCH_DATA,
|
| |
+ + 0, 0, NULL, NULL,
|
| |
+ + spell);
|
| |
+ + }
|
| |
+ g_free(spell->word);
|
| |
+ g_free(spell);
|
| |
+ }
|
| |
+ @@ -645,6 +647,7 @@
|
| |
+ /* attach to the widget */
|
| |
+ spell = g_new0(spellchk, 1);
|
| |
+ spell->view = view;
|
| |
+ + g_object_add_weak_pointer(G_OBJECT(view), (gpointer*)&spell->view);
|
| |
+
|
| |
+ g_object_set_data_full(G_OBJECT(view), SPELLCHK_OBJECT_KEY, spell,
|
| |
+ (GDestroyNotify)spellchk_free);
|
| |
+ @@ -2139,6 +2142,8 @@
|
| |
+ spellchk *spell = g_object_get_data(G_OBJECT(gtkconv->entry), SPELLCHK_OBJECT_KEY);
|
| |
+
|
| |
+ g_signal_handlers_disconnect_by_func(gtkconv->entry, message_send_cb, spell);
|
| |
+ + g_object_remove_weak_pointer(G_OBJECT(gtkconv->entry),
|
| |
+ + (gpointer*)&spell->view);
|
| |
+ g_object_set_data(G_OBJECT(gtkconv->entry), SPELLCHK_OBJECT_KEY, NULL);
|
| |
+ }
|
| |
+
|
| |
This has bugged me for a long time, now there is an upstream fix.
If you accept this, please also backport this to Fedora 37. I am on rawhide (~= Fedora 38), but I have to assume this is still present on Fedora 37
I built this change in copr and verified the fix works: https://copr.fedorainfracloud.org/coprs/jackorp/pidgin_spellchk/
Resolves: rhbz#2112810
Upstream references:
Upstream ticket: https://issues.imfreedom.org/issue/PIDGIN-17702/
Upstream review: https://reviews.imfreedom.org/r/1951/diff/2/
Upstream commit: https://keep.imfreedom.org/pidgin/pidgin/rev/bf6049713e98