Let's try __attribute__ this time for unused vars.
authorBrenden Matthews <brenden@rty.ca>
Mon, 3 Aug 2009 19:48:18 +0000 (13:48 -0600)
committerBrenden Matthews <brenden@rty.ca>
Mon, 3 Aug 2009 19:48:18 +0000 (13:48 -0600)
src/conky.h
src/weather.c

index 9a1d4e1..d88e3c5 100644 (file)
@@ -387,5 +387,6 @@ void set_update_interval(double interval);
 
 /* to get rid of 'unused variable' warnings */
 #define UNUSED(a)  (void)a
+#define UNUSED_ATTR __attribute__ ((unused))
 
 #endif /* _conky_h_ */
index 1e43283..de496e1 100644 (file)
@@ -781,11 +781,10 @@ void load_xoap_keys(void)
 }
 #endif /* XOAP */
 
-int process_weather_uri(char *uri, char *locID, int dayf)
+int process_weather_uri(char *uri, char *locID, int dayf UNUSED_ATTR)
 {
        /* locID MUST BE upper-case */
        char *tmp_p = locID;
-       UNUSED(dayf); /* make gcc shut up */
 
        while (*tmp_p) {
                *tmp_p = toupper(*tmp_p);