From c99e09224604b16deb8882071a0a59d4ba17b672 Mon Sep 17 00:00:00 2001 From: Nikolas Garofil Date: Tue, 4 Aug 2009 22:13:06 +0200 Subject: [PATCH 1/1] Gcc complains too much when build without X11 and NCurses --- src/conky.c | 5 +++-- src/specials.c | 2 ++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/conky.c b/src/conky.c index 6661580..20a8fbd 100644 --- a/src/conky.c +++ b/src/conky.c @@ -6584,6 +6584,7 @@ static inline void set_foreground_color(long c) attron(COLOR_PAIR(c)); } #endif /* NCURSES */ + UNUSED(c); return; } @@ -7175,8 +7176,8 @@ static int draw_line(char *s, int special_index) } #endif /* NCURSES */ draw_string(s); - //'special_index - special_index' instead of 0 otherwise gcc complains about not using special_index when build without X11 - return special_index - special_index; + UNUSED(special_index); + return 0; } static void draw_text(void) diff --git a/src/specials.c b/src/specials.c index 71df3de..536cae7 100644 --- a/src/specials.c +++ b/src/specials.c @@ -363,6 +363,8 @@ void new_fg(char *buf, long c) if (output_methods & TO_NCURSES) new_special(buf, FG)->arg = c; #endif /* NCURSES */ + UNUSED(buf); + UNUSED(c); } #ifdef X11 -- 1.7.9.5