Fri, 16 Nov 2007 18:43:50 +0000
There appears to be a new GTK+ bug that causes the clipboard_clear callback to be triggered *after* the clipboard_copy callback on the second copy attempt. This makes stuff still work correctly when this happens (and, most importantly, not crash). I'll report this upstream.
| pidgin/gtkimhtml.c | file | annotate | diff | comparison | revisions |
--- a/pidgin/gtkimhtml.c Fri Nov 16 17:38:53 2007 +0000 +++ b/pidgin/gtkimhtml.c Fri Nov 16 18:43:50 2007 +0000 @@ -899,6 +899,9 @@ if (primary) { GtkTextMark *sel = NULL, *ins = NULL; + + g_return_if_fail(imhtml != NULL); + ins = gtk_text_buffer_get_insert(imhtml->text_buffer); sel = gtk_text_buffer_get_selection_bound(imhtml->text_buffer); gtk_text_buffer_get_iter_at_mark(imhtml->text_buffer, &start, sel); @@ -957,7 +960,9 @@ static void gtk_imhtml_clipboard_clear (GtkClipboard *clipboard, GtkSelectionData *sel_data, guint info, gpointer user_data_or_owner) { +#ifndef _WIN32 clipboard_selection = NULL; +#endif } static void copy_clipboard_cb(GtkIMHtml *imhtml, gpointer unused)