summaryrefslogtreecommitdiffstats
path: root/widget/gtk
diff options
context:
space:
mode:
authorMoonchild <mcwerewolf@gmail.com>2018-06-07 03:18:16 +0200
committerGitHub <noreply@github.com>2018-06-07 03:18:16 +0200
commit99f072c63221631ce11ab5f4d65915b5f22a9de5 (patch)
treedb6b74ea9315161eaa342c8c60eee57b3547f3bb /widget/gtk
parent4a71b30364a4b6d1eaf16fcfdc8e873e6697f293 (diff)
parent8e9811c71b25733728b53a20642adaeb1a9c9d3d (diff)
downloadUXP-99f072c63221631ce11ab5f4d65915b5f22a9de5.tar
UXP-99f072c63221631ce11ab5f4d65915b5f22a9de5.tar.gz
UXP-99f072c63221631ce11ab5f4d65915b5f22a9de5.tar.lz
UXP-99f072c63221631ce11ab5f4d65915b5f22a9de5.tar.xz
UXP-99f072c63221631ce11ab5f4d65915b5f22a9de5.zip
Merge pull request #460 from g4jc/gtk_null_fix
backport mozbug #546387: fix assert failure in gtk which prints to the console
Diffstat (limited to 'widget/gtk')
-rw-r--r--widget/gtk/nsClipboard.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/widget/gtk/nsClipboard.cpp b/widget/gtk/nsClipboard.cpp
index 053ae970e..eecae3e88 100644
--- a/widget/gtk/nsClipboard.cpp
+++ b/widget/gtk/nsClipboard.cpp
@@ -214,7 +214,8 @@ nsClipboard::SetData(nsITransferable *aTransferable,
GtkTargetEntry *gtkTargets = gtk_target_table_new_from_list(list, &numTargets);
// Set getcallback and request to store data after an application exit
- if (gtk_clipboard_set_with_data(gtkClipboard, gtkTargets, numTargets,
+ if (gtkTargets &&
+ gtk_clipboard_set_with_data(gtkClipboard, gtkTargets, numTargets,
clipboard_get_cb, clipboard_clear_cb, this))
{
// We managed to set-up the clipboard so update internal state