From 2f8b6a0349547742ca011a6b786c93839477ae33 Mon Sep 17 00:00:00 2001 From: Erik de Castro Lopo Date: Mon, 5 Mar 2012 21:12:20 +1100 Subject: [PATCH] Rename ENDSWAP_INT to ENDSWAP_32. --- include/share/endswap.h | 8 ++++---- src/libFLAC/bitreader.c | 2 +- src/libFLAC/bitwriter.c | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/include/share/endswap.h b/include/share/endswap.h index e481d45..b9beaff 100644 --- a/include/share/endswap.h +++ b/include/share/endswap.h @@ -33,21 +33,21 @@ #if HAVE_BSWAP32 /* GCC and Clang */ -#define ENDSWAP_INT(x) (__builtin_bswap32 (x)) +#define ENDSWAP_32(x) (__builtin_bswap32 (x)) #elif defined _MSC_VER /* Windows. Apparently in . */ -#define ENDSWAP_INT(x) ((int) _byteswap_ulong (x)) +#define ENDSWAP_32(x) (_byteswap_ulong (x)) #elif HAVE_BYTESWAP_H /* Linux */ #include -#define ENDSWAP_INT(x) ((int) bswap_32 (x)) +#define ENDSWAP_32(x) (bswap_32 (x)) #else -#define ENDSWAP_INT(x) ((((x) >> 24) & 0xFF) + (((x) >> 8) & 0xFF00) + (((x) & 0xFF00) << 8) + (((x) & 0xFF) << 24)) +#define ENDSWAP_32(x) ((((x) >> 24) & 0xFF) + (((x) >> 8) & 0xFF00) + (((x) & 0xFF00) << 8) + (((x) & 0xFF) << 24)) #endif diff --git a/src/libFLAC/bitreader.c b/src/libFLAC/bitreader.c index b4e44ed..c3edd16 100644 --- a/src/libFLAC/bitreader.c +++ b/src/libFLAC/bitreader.c @@ -53,7 +53,7 @@ typedef FLAC__uint32 brword; #if WORDS_BIGENDIAN #define SWAP_BE_WORD_TO_HOST(x) (x) #else -#define SWAP_BE_WORD_TO_HOST(x) ENDSWAP_INT(x) +#define SWAP_BE_WORD_TO_HOST(x) ENDSWAP_32(x) #endif /* counts the # of zero MSBs in a word */ #define COUNT_ZERO_MSBS(word) ( \ diff --git a/src/libFLAC/bitwriter.c b/src/libFLAC/bitwriter.c index ed7d379..60fb560 100644 --- a/src/libFLAC/bitwriter.c +++ b/src/libFLAC/bitwriter.c @@ -52,7 +52,7 @@ typedef FLAC__uint32 bwword; #if WORDS_BIGENDIAN #define SWAP_BE_WORD_TO_HOST(x) (x) #else -#define SWAP_BE_WORD_TO_HOST(x) ENDSWAP_INT(x) +#define SWAP_BE_WORD_TO_HOST(x) ENDSWAP_32(x) #endif /* -- 2.7.4