[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1429691227-12310-1-git-send-email-nicolas.dichtel@6wind.com>
Date: Wed, 22 Apr 2015 10:27:05 +0200
From: Nicolas Dichtel <nicolas.dichtel@...nd.com>
To: shemminger@...tta.com, david.laight@...lab.com
Cc: netdev@...r.kernel.org, Nicolas Dichtel <nicolas.dichtel@...nd.com>
Subject: [PATCH v2 iproute2 1/3] tc: fix compilation warning on 32bits arch
The warning was:
m_simple.c: In function ‘parse_simple’:
m_simple.c:142:4: warning: format ‘%ld’ expects argument of type ‘long int’, but argument 3 has type ‘size_t’ [-Wformat]
Useful to be able to compile with -Werror.
Signed-off-by: Nicolas Dichtel <nicolas.dichtel@...nd.com>
---
v2: use %zu instead of casting to a long
tc/m_simple.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tc/m_simple.c b/tc/m_simple.c
index 866552f559b3..1ad55268729c 100644
--- a/tc/m_simple.c
+++ b/tc/m_simple.c
@@ -138,7 +138,7 @@ parse_simple(struct action_util *a, int *argc_p, char ***argv_p, int tca_id,
}
if (strlen(simpdata) > (SIMP_MAX_DATA - 1)) {
- fprintf(stderr, "simple: Illegal string len %ld <%s> \n",
+ fprintf(stderr, "simple: Illegal string len %zu <%s> \n",
strlen(simpdata), simpdata);
return -1;
}
--
2.2.2
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists