Commit 2dff889e by Roman Lechtchinsky Committed by Richard Henderson

* gettextP.h (SWAP): Change parameter type to unsigned int.

From-SVN: r53878
parent 81a75f0f
2002-05-25 Roman Lechtchinsky <rl@cs.tu-berlin.de>
* gettextP.h (SWAP): Change parameter type to unsigned int.
Tue Dec 11 07:08:57 2001 Douglas B. Rupp <rupp@gnat.com> Tue Dec 11 07:08:57 2001 Douglas B. Rupp <rupp@gnat.com>
* localealias.c (strings.h): Include. * localealias.c (strings.h): Include.
......
...@@ -63,12 +63,14 @@ ...@@ -63,12 +63,14 @@
# include <byteswap.h> # include <byteswap.h>
# define SWAP(i) bswap_32 (i) # define SWAP(i) bswap_32 (i)
#else #else
/* GCC LOCAL: Prototype first to avoid warnings. */ /* GCC LOCAL: Prototype first to avoid warnings; change argument to
static inline nls_uint32 SWAP PARAMS ((nls_uint32)); unsigned int to avoid K&R type promotion errors with 64-bit "int". */
static inline nls_uint32 SWAP PARAMS ((unsigned int));
static inline nls_uint32 static inline nls_uint32
SWAP (i) SWAP (i)
nls_uint32 i; unsigned int ii;
{ {
nls_uint32 i = ii;
return (i << 24) | ((i & 0xff00) << 8) | ((i >> 8) & 0xff00) | (i >> 24); return (i << 24) | ((i & 0xff00) << 8) | ((i >> 8) & 0xff00) | (i >> 24);
} }
#endif #endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment