diff options
author | Alexander Schwinn <acs82@gmx.de> | 2018-06-19 22:39:50 +0200 |
---|---|---|
committer | Alexander Schwinn <acs82@gmx.de> | 2018-06-19 22:39:50 +0200 |
commit | 4fa24d42f83180fd5012527eb4ed77b04e8d88a6 (patch) | |
tree | 8a2740b35842bfc0ad84fd52d8b6ae3451d59540 /plugins | |
parent | 6695bf356efe48a8c15e9d000ac63344196c1343 (diff) | |
download | thunar-4fa24d42f83180fd5012527eb4ed77b04e8d88a6.tar.gz |
Segfault in XInternAtom when clicking or typing when using wayland (Bug
#14461)
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/thunar-wallpaper/twp-provider.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/plugins/thunar-wallpaper/twp-provider.c b/plugins/thunar-wallpaper/twp-provider.c index 0a91c1d6..66c761e1 100644 --- a/plugins/thunar-wallpaper/twp-provider.c +++ b/plugins/thunar-wallpaper/twp-provider.c @@ -23,6 +23,8 @@ #include <config.h> #endif +#include <stdlib.h> + #include <gio/gio.h> #include <gdk/gdkx.h> @@ -180,6 +182,12 @@ twp_provider_get_file_menu_items (ThunarxMenuProvider *menu_provider, } g_snprintf(selection_name, 100, XFDESKTOP_SELECTION_FMT, xscreen); + + if(g_strcmp0 (getenv("XDG_SESSION_TYPE"),"wayland") == 0) + { + return items; // wayland crashes on "gdk_x11_get_default_xdisplay" + } + xfce_selection_atom = XInternAtom (gdk_x11_get_default_xdisplay(), selection_name, False); if ((XGetSelectionOwner(gdk_x11_get_default_xdisplay(), xfce_selection_atom))) |