summaryrefslogtreecommitdiff
path: root/vcl/unx/gtk3
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2016-02-09 14:13:48 +0100
committerMichael Stahl <mstahl@redhat.com>2016-02-09 14:17:40 +0100
commit678e0ea1472478d248d1a45c1e0ade5ed84f9d46 (patch)
treef91397f9814ffc4de54e2d4fca03a56c121c5247 /vcl/unx/gtk3
parente14bd2d6845cf13a35b14762d6e1e160e8315997 (diff)
vcl, libreofficekit: gtk_clipboard_wait_for_contents() may return null
Don't crash then. Change-Id: I4980fe4ea56e023cbf303fa43d1e6b383d983d2e
Diffstat (limited to 'vcl/unx/gtk3')
-rw-r--r--vcl/unx/gtk3/gtk3gtkinst.cxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/vcl/unx/gtk3/gtk3gtkinst.cxx b/vcl/unx/gtk3/gtk3gtkinst.cxx
index f914e4546f6a..32e1a5722fac 100644
--- a/vcl/unx/gtk3/gtk3gtkinst.cxx
+++ b/vcl/unx/gtk3/gtk3gtkinst.cxx
@@ -206,6 +206,10 @@ public:
css::uno::Any aRet;
GtkSelectionData* data = gtk_clipboard_wait_for_contents(clipboard,
it->second);
+ if (!data)
+ {
+ return css::uno::Any();
+ }
gint length;
const guchar *rawdata = gtk_selection_data_get_data_with_length(data,
&length);