Add a proper error message if connection to the X server can’t be established
This commit is contained in:
parent
d70ea03356
commit
55f0aa8f28
@ -144,6 +144,9 @@ int main(int argc, char *argv[], char *env[]) {
|
|||||||
|
|
||||||
conn = xcb_connect(NULL, &screens);
|
conn = xcb_connect(NULL, &screens);
|
||||||
|
|
||||||
|
if (xcb_connection_has_error(conn))
|
||||||
|
die("Cannot open display\n");
|
||||||
|
|
||||||
load_configuration(conn, override_configpath);
|
load_configuration(conn, override_configpath);
|
||||||
|
|
||||||
/* Place requests for the atoms we need as soon as possible */
|
/* Place requests for the atoms we need as soon as possible */
|
||||||
|
Loading…
Reference in New Issue
Block a user