Eliminate once-used check_error utility function

This commit is contained in:
Michael Stapelberg
2016-09-14 09:19:25 +02:00
parent d48c9b1e33
commit 5594139676
3 changed files with 5 additions and 23 deletions

View File

@ -538,7 +538,11 @@ int main(int argc, char *argv[]) {
xcb_void_cookie_t cookie;
cookie = xcb_change_window_attributes_checked(conn, root, XCB_CW_EVENT_MASK, (uint32_t[]){ROOT_EVENT_MASK});
check_error(conn, cookie, "Another window manager seems to be running");
xcb_generic_error_t *error = xcb_request_check(conn, cookie);
if (error != NULL) {
ELOG("Another window manager seems to be running (X error %d)\n", error->error_code);
return 1;
}
xcb_get_geometry_reply_t *greply = xcb_get_geometry_reply(conn, gcookie, NULL);
if (greply == NULL) {