summaryrefslogtreecommitdiff
path: root/xfce4-session/xfsm-logout-dialog.c
diff options
context:
space:
mode:
Diffstat (limited to 'xfce4-session/xfsm-logout-dialog.c')
-rw-r--r--xfce4-session/xfsm-logout-dialog.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/xfce4-session/xfsm-logout-dialog.c b/xfce4-session/xfsm-logout-dialog.c
index 53745518..c86a1556 100644
--- a/xfce4-session/xfsm-logout-dialog.c
+++ b/xfce4-session/xfsm-logout-dialog.c
@@ -588,6 +588,14 @@ xfsm_logout_dialog_screenshot_save (GdkPixbuf *screenshot,
g_free (display_name);
g_free (path);
+ if (!filename)
+ {
+ g_warning ("Unable to save screenshot, "
+ "error calling xfce_resource_save_location with %s, "
+ "check your permissions", path);
+ return;
+ }
+
if (!gdk_pixbuf_save (scaled, filename, "png", &error, NULL))
{
g_warning ("Failed to save session screenshot: %s", error->message);