From 01cc63aa4540d5fa20f948540e40b0150fcaa480 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Helleu?= Date: Mon, 25 Sep 2017 20:12:31 +0200 Subject: [PATCH] core: initialize variables attrs and pair before calling wattr_get This fixes a compiler warning, in some cases wattr_get may not initialize the variables. --- src/gui/curses/gui-curses-window.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/gui/curses/gui-curses-window.c b/src/gui/curses/gui-curses-window.c index a95b2724e..98b4a5aa1 100644 --- a/src/gui/curses/gui-curses-window.c +++ b/src/gui/curses/gui-curses-window.c @@ -570,6 +570,8 @@ gui_window_emphasize (WINDOW *window, int x, int y, int count) else { /* exclusive or (XOR) with attributes */ + attrs = 0; + pair = 0; ptr_attrs = &attrs; ptr_pair = &pair; wattr_get (window, ptr_attrs, ptr_pair, NULL);