From: Christophe CURIS <[email protected]>

As callback have a fixed prototype, it can be correct to not use all the
arguments, so this patch adds the appropriate stuff to avoid a false
report from compiler.

Signed-off-by: Christophe CURIS <[email protected]>
---
 WINGs/menuparser_macros.c | 3 +++
 WINGs/proplist.c          | 4 ++++
 WINGs/userdefaults.c      | 3 +++
 3 files changed, 10 insertions(+)

diff --git a/WINGs/menuparser_macros.c b/WINGs/menuparser_macros.c
index 511334f..2b093db 100644
--- a/WINGs/menuparser_macros.c
+++ b/WINGs/menuparser_macros.c
@@ -679,6 +679,9 @@ static void mpm_get_user_name(WParserMacro *this, 
WMenuParser parser)
 /* Number id of the user under which we are running */
 static void mpm_get_user_id(WParserMacro *this, WMenuParser parser)
 {
+       /* Parameter not used, but tell the compiler that it is ok */
+       (void) parser;
+
        if (this->value[0] != '\0') return; // Already evaluated, re-use 
previous
        snprintf((char *) this->value, sizeof(this->value), "%d", getuid() );
 }
diff --git a/WINGs/proplist.c b/WINGs/proplist.c
index 49cc53f..beb209d 100644
--- a/WINGs/proplist.c
+++ b/WINGs/proplist.c
@@ -1766,6 +1766,10 @@ int wmkdirhier(const char *path)
 static int wrmdirhier_fn(const char *path, const struct stat *st,
     int type, struct FTW *ftw)
 {
+       /* Parameter not used, but tell the compiler that it is ok */
+       (void) st;
+       (void) ftw;
+
        switch(type) {
        case FTW_D:
                break;
diff --git a/WINGs/userdefaults.c b/WINGs/userdefaults.c
index 2947331..160a08b 100644
--- a/WINGs/userdefaults.c
+++ b/WINGs/userdefaults.c
@@ -136,6 +136,9 @@ static void synchronizeUserDefaults(void *foo)
 {
        UserDefaults *database = sharedUserDefaults;
 
+       /* Parameter not used, but tell the compiler that it is ok */
+       (void) foo;
+
        while (database) {
                if (!database->dontSync)
                        WMSynchronizeUserDefaults(database);
-- 
1.8.4.rc3


-- 
To unsubscribe, send mail to [email protected].

Reply via email to