aboutsummaryrefslogtreecommitdiffstats
path: root/src/session.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/session.c')
-rw-r--r--src/session.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/session.c b/src/session.c
index 958e804b8..9df93ca14 100644
--- a/src/session.c
+++ b/src/session.c
@@ -444,6 +444,12 @@ session_save (Session *session,
xmlDocPtr doc;
char *save_to;
+ if (session->priv->windows == NULL)
+ {
+ session_delete (session, filename);
+ return;
+ }
+
save_to = get_session_filename (filename);
doc = xmlNewDoc ("1.0");