diff --git a/examples/cluster.c b/examples/cluster.c index 505f2fc..172cab1 100644 --- a/examples/cluster.c +++ b/examples/cluster.c @@ -203,13 +203,13 @@ int main(int argc, char **argv) { Window win; Pixmap buf; GC gc; - fd_set rfds, wfds, rready, wready; + fd_set rfds, rready; hexagram_can_if *can_if; int screen, fd, fd2, - width = 1024, - height = 480; + width = 480, + height = 224; XGCValues values = { .foreground = 0x000000, @@ -248,7 +248,7 @@ int main(int argc, char **argv) { FD_SET(fd2, &rfds); while (1) { - int nready, pending; + int pending; while ((pending = XPending(display)) != 0) { XEvent e; @@ -291,12 +291,11 @@ int main(int argc, char **argv) { draw_gauge_cluster(cr, &frame, 0, 0, width, height); XCopyArea(display, buf, win, gc, 0, 0, - 1024, 480, + width, height, 0, 0); } } -done: cairo_destroy(cr); cairo_surface_destroy(sfc);