aboutsummaryrefslogtreecommitdiff
path: root/backend/session
diff options
context:
space:
mode:
authorKenny Levinsen <kl@kl.wtf>2021-04-18 18:20:01 +0200
committerSimon Ser <contact@emersion.fr>2021-04-18 18:32:24 +0200
commit3432ab2ba7d7c65d39c766f902ac915b60af52fd (patch)
treefe1ff141e22279583497c9745c087c6374b70bb1 /backend/session
parente7515529ce930913998e1482b25bcf90ec1a7aad (diff)
backend/session: Close remaining devices on destroy
Diffstat (limited to 'backend/session')
-rw-r--r--backend/session/session.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/backend/session/session.c b/backend/session/session.c
index 314f931e..8ca858c8 100644
--- a/backend/session/session.c
+++ b/backend/session/session.c
@@ -265,6 +265,11 @@ void wlr_session_destroy(struct wlr_session *session) {
udev_monitor_unref(session->mon);
udev_unref(session->udev);
+ struct wlr_device *dev, *tmp_dev;
+ wl_list_for_each_safe(dev, tmp_dev, &session->devices, link) {
+ wlr_session_close_file(session, dev);
+ }
+
libseat_session_finish(session);
free(session);
}