From ddab20176b8fe5d8c5388c4cd647e47f73c21e71 Mon Sep 17 00:00:00 2001 From: Yuxuan Shui Date: Sun, 30 Sep 2018 20:43:34 +0100 Subject: [PATCH] Fix building with ENABLE_XRESCHECK=1 --- src/xrescheck.h | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/xrescheck.h b/src/xrescheck.h index 55c97815..a783f8f3 100644 --- a/src/xrescheck.h +++ b/src/xrescheck.h @@ -2,7 +2,7 @@ #define COMPTON_XRESCHECK_H #include "common.h" -#include +#include "uthash.h" typedef struct { XID xid; @@ -45,11 +45,10 @@ xcb_create_pixmap_(xcb_connection_t *c, uint8_t depth, xcb_pixmap_t pixmap, #define xcb_create_pixmap(c, depth, pixmap, drawable, width, height) \ xcb_create_pixmap_(c, depth, pixmap, drawable, width, height, M_POS_DATA) -static inline xcb_pixmap_t +static inline xcb_void_cookie_t xcb_composite_name_window_pixmap_(xcb_connection_t *c, xcb_window_t window, xcb_pixmap_t pixmap, M_POS_DATA_PARAMS) { - xcb_pixmap_t ret = xcb_composite_name_window_pixmap(c, window, pixmap); - if (ret) - xrc_add_xid_(ret, "PixmapC", M_POS_DATA_PASSTHROUGH); + xcb_void_cookie_t ret = xcb_composite_name_window_pixmap(c, window, pixmap); + xrc_add_xid_(pixmap, "PixmapC", M_POS_DATA_PASSTHROUGH); return ret; }