--- a/xdemo.c +++ b/xdemo.c @@ -10,8 +10,11 @@ int main (int argc, char **argv) { Window w = 0; + Display *dpy = XOpenDisplay (NULL); + XEvent xev; + int active; if (dpy == NULL) {