|
From: | Dan Oetting |
Subject: | Re: format specifier warning on wchar_t |
Date: | Fri, 13 Jan 2006 17:18:16 -0700 |
On Jan 13, 2006, at 2:39 PM, Pawel Kot wrote:
I'm using Xcode on OS X 10.4.4 which in turn uses gcc version 4.0.0 20041026. The warning parameters have been adjusted to get rid of the majority of mostly safe warnings (like -Wno-pointer-sign) and turned up looking for some potentially platform dependent bugs (like -Wformat) Is this better for the diff? Index: gsm-encoding.c =================================================================== RCS file: /sources/gnokii/gnokii/common/gsm-encoding.c,v retrieving revision 1.64 diff -d -p --unified=3 -r1.64 gsm-encoding.c --- gsm-encoding.c 31 Jul 2005 21:42:31 -0000 1.64 +++ gsm-encoding.c 14 Jan 2006 00:05:04 -0000 @@ -425,7 +425,7 @@ void char_ucs2_encode(unsigned char* des i_len += length; break; } - sprintf(dest + (o_len << 2), "%04lx", wc); + sprintf(dest + (o_len << 2), "%04x", (int)wc); } return; } |
[Prev in Thread] | Current Thread | [Next in Thread] |