Quit if set or drop master fails

This commit is contained in:
Kristian Høgsberg 2010-06-06 22:43:55 -04:00
parent 27803c6859
commit 6a9bbd0db2

View File

@ -1381,6 +1381,7 @@ static void on_enter_vt(int signal_number, void *data)
ret = drmSetMaster(ec->drm_fd);
if (ret) {
fprintf(stderr, "failed to set drm master\n");
on_term_signal(SIGTERM, ec);
return;
}
@ -1405,6 +1406,7 @@ static void on_leave_vt(int signal_number, void *data)
ret = drmDropMaster(ec->drm_fd);
if (ret) {
fprintf(stderr, "failed to drop drm master\n");
on_term_signal(SIGTERM, ec);
return;
}