summaryrefslogtreecommitdiff
path: root/src/wayland/meta-xwayland.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/wayland/meta-xwayland.c')
-rw-r--r--src/wayland/meta-xwayland.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/wayland/meta-xwayland.c b/src/wayland/meta-xwayland.c
index ad6667ea..a7beb0c1 100644
--- a/src/wayland/meta-xwayland.c
+++ b/src/wayland/meta-xwayland.c
@@ -532,5 +532,10 @@ meta_xwayland_stop (MetaXWaylandManager *manager)
snprintf (path, sizeof path, "/tmp/.X11-unix/X%d", manager->display_index);
unlink (path);
- unlink (manager->lock_file);
+ g_clear_pointer (&manager->display_name, g_free);
+ if (manager->lock_file)
+ {
+ unlink (manager->lock_file);
+ g_clear_pointer (&manager->lock_file, g_free);
+ }
}