From: Hans de Goede Date: Mon, 3 Mar 2014 08:51:36 +0000 (+0100) Subject: hashtabletest: Fix warning: format ‘%ld’ expects argument of type ... X-Git-Tag: upstream/1.15.99.902~75 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=2f2967173ba0b0a4f7ab013edeaaf11e7c181beb;p=platform%2Fupstream%2Fxorg-server.git hashtabletest: Fix warning: format ‘%ld’ expects argument of type ... This fixes the following compiler warning: hashtabletest.c: In function ‘print_xid’: hashtabletest.c:15:5: warning: format ‘%ld’ expects argument of type ‘long int’, but argument 2 has type ‘XID’ [-Wformat=] printf("%ld", *x); ^ Signed-off-by: Hans de Goede Reviewed-by: Eric Anholt --- diff --git a/test/hashtabletest.c b/test/hashtabletest.c index ceadfa7..86a0c58 100644 --- a/test/hashtabletest.c +++ b/test/hashtabletest.c @@ -12,7 +12,7 @@ static void print_xid(void* ptr, void* v) { XID *x = v; - printf("%ld", *x); + printf("%ld", (long)(*x)); } static void