core: failed to ungrab server should be fatal

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
Yuxuan Shui 2020-03-28 00:18:07 +00:00
parent 23068c300c
commit 3ba7a2aa4d
No known key found for this signature in database
GPG Key ID: 37C999F617EA1A47
1 changed files with 4 additions and 2 deletions

View File

@ -2096,7 +2096,8 @@ static session_t *session_init(int argc, char **argv, Display *dpy,
e = xcb_request_check(ps->c, xcb_grab_server_checked(ps->c));
if (e) {
log_fatal("Failed to grab X server");
log_fatal_x_error(e, "Failed to grab X server");
free(e);
goto err;
}
@ -2113,8 +2114,9 @@ static session_t *session_init(int argc, char **argv, Display *dpy,
e = xcb_request_check(ps->c, xcb_ungrab_server(ps->c));
if (e) {
log_error_x_error(e, "Failed to ungrab server");
log_fatal_x_error(e, "Failed to ungrab server");
free(e);
goto err;
}
ps->server_grabbed = false;