diff options
author | Eddy Jansson <eddy@klopper.net> | 2021-07-31 16:59:15 (GMT) |
---|---|---|
committer | Eddy Jansson <eddy@klopper.net> | 2021-07-31 16:59:15 (GMT) |
commit | 80e3e7034e84e7ff250d7f992ac7337551f800e8 (patch) | |
tree | 5db16ceb7dba08fa5c6e8505b07f0c45dc50bd6a /lib | |
parent | 4de56b3da3f709e61301d65cf67e068bc650d9eb (diff) | |
download | lz4-80e3e7034e84e7ff250d7f992ac7337551f800e8.zip lz4-80e3e7034e84e7ff250d7f992ac7337551f800e8.tar.gz lz4-80e3e7034e84e7ff250d7f992ac7337551f800e8.tar.bz2 |
Define LZ4_STREAMSIZE in terms of LZ4_MEMORY_USAGE
This is required to correctly size a static member
to hold the hash table, whose size is derived from
LZ4_MEMORY_USAGE.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/lz4.h | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -620,7 +620,7 @@ typedef struct { * note : only use this definition in association with static linking ! * this definition is not API/ABI safe, and may change in future versions. */ -#define LZ4_STREAMSIZE 16416 /* static size, for inter-version compatibility */ +#define LZ4_STREAMSIZE ((1UL << LZ4_MEMORY_USAGE) + 32) /* static size, for inter-version compatibility */ #define LZ4_STREAMSIZE_VOIDP (LZ4_STREAMSIZE / sizeof(void*)) union LZ4_stream_u { void* table[LZ4_STREAMSIZE_VOIDP]; |