summaryrefslogtreecommitdiff
path: root/src/libsystemd-terminal/modeset.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libsystemd-terminal/modeset.c')
-rw-r--r--src/libsystemd-terminal/modeset.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libsystemd-terminal/modeset.c b/src/libsystemd-terminal/modeset.c
index 7a28e7ab97..f564fa0f65 100644
--- a/src/libsystemd-terminal/modeset.c
+++ b/src/libsystemd-terminal/modeset.c
@@ -332,7 +332,8 @@ static int modeset_sysview_fn(sysview_context *c, void *userdata, sysview_event
grdev_session_restore(m->grdev_session);
grdev_session_disable(m->grdev_session);
m->grdev_session = grdev_session_free(m->grdev_session);
- sd_event_exit(m->event, 0);
+ if (sd_event_get_exit_code(m->event, &r) == -ENODATA)
+ sd_event_exit(m->event, 0);
break;
case SYSVIEW_EVENT_SESSION_ATTACH:
d = ev->session_attach.device;