From fe8aa55fdcbb95fc72f9798095aee1e3562a6fd1 Mon Sep 17 00:00:00 2001 From: Dave Davenport Date: Thu, 3 Mar 2016 16:02:14 +0100 Subject: [PATCH] Correctly check error --- source/rofi.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/source/rofi.c b/source/rofi.c index ae4530c4..97d15702 100644 --- a/source/rofi.c +++ b/source/rofi.c @@ -632,10 +632,11 @@ int main ( int argc, char *argv[] ) xcb->screen = xcb_aux_get_screen ( xcb->connection, xcb->screen_nbr ); xcb_intern_atom_cookie_t *ac = xcb_ewmh_init_atoms ( xcb->connection, &xcb->ewmh ); - xcb_generic_error_t **errors = NULL; - xcb_ewmh_init_atoms_replies ( &xcb->ewmh, ac, errors ); + xcb_generic_error_t *errors = NULL; + xcb_ewmh_init_atoms_replies ( &xcb->ewmh, ac, &errors ); if ( errors ) { fprintf ( stderr, "Failed to create EWMH atoms\n" ); + free(errors); } if ( xkb_x11_setup_xkb_extension ( xcb->connection, XKB_X11_MIN_MAJOR_XKB_VERSION, XKB_X11_MIN_MINOR_XKB_VERSION,