diff options
author | Yann Collet <yann.collet.73@gmail.com> | 2014-11-29 15:41:28 (GMT) |
---|---|---|
committer | Yann Collet <yann.collet.73@gmail.com> | 2014-11-29 15:41:28 (GMT) |
commit | dc43a1f6b5373e4e931f09b89ae7680be5afca69 (patch) | |
tree | deb8b1c5d4844a78a89903112d8d11085acb44dc /programs | |
parent | e3d1b4e020d9b34ebfa688270e2a1ca3fd4fecdf (diff) | |
download | lz4-dc43a1f6b5373e4e931f09b89ae7680be5afca69.zip lz4-dc43a1f6b5373e4e931f09b89ae7680be5afca69.tar.gz lz4-dc43a1f6b5373e4e931f09b89ae7680be5afca69.tar.bz2 |
Fixed : decompression issue on 32-bits CPU without unaligned memory access
Diffstat (limited to 'programs')
-rw-r--r-- | programs/lz4cli.c | 15 |
1 files changed, 1 insertions, 14 deletions
diff --git a/programs/lz4cli.c b/programs/lz4cli.c index 9a6e5bc..6e52ec6 100644 --- a/programs/lz4cli.c +++ b/programs/lz4cli.c @@ -48,10 +48,6 @@ # pragma warning(disable : 4127) // disable: C4127: conditional expression is constant #endif -#ifdef __clang__ -# pragma clang diagnostic ignored "-Wunused-const-variable" // const variable one is really used ! -#endif - #define _FILE_OFFSET_BITS 64 // Large file support on 32-bits unix #define _POSIX_SOURCE 1 // for fileno() within <stdio.h> on unix @@ -128,15 +124,6 @@ //************************************** -// Architecture Macros -//************************************** -static const int one = 1; -#define CPU_LITTLE_ENDIAN (*(char*)(&one)) -#define CPU_BIG_ENDIAN (!CPU_LITTLE_ENDIAN) -#define LITTLE_ENDIAN_32(i) (CPU_LITTLE_ENDIAN?(i):swap32(i)) - - -//************************************** // Macros //************************************** #define DISPLAY(...) fprintf(stderr, __VA_ARGS__) @@ -462,7 +449,7 @@ int main(int argc, char** argv) } DISPLAYLEVEL(3, WELCOME_MESSAGE); - DISPLAYLEVEL(4, "Blocks size : %i KB\n", blockSize>>10); + if (!decode) DISPLAYLEVEL(4, "Blocks size : %i KB\n", blockSize>>10); // No input filename ==> use stdin if(!input_filename) { input_filename=stdinmark; } |