Yann Collet
e22bb80074
fixed fuzzer test
...
and removed one blind copy, since there is no more guarantee that at least 4 bytes are still available in output buffer
2018-09-07 18:22:01 -07:00
Yann Collet
bf614d3c51
first sketch for a byte-accurate partial decoder
2018-09-07 15:44:19 -07:00
Yann Collet
30f6f34328
removed one assert() condition
...
which is not correct when using LZ4_HC with dictionary and starting from a low address (<0x10000).
2018-09-05 11:25:10 -07:00
Norm Green
ebe7e35601
Fix AIX 32 bit build problem of fuzzer.c
2018-06-01 11:52:22 -07:00
Yann Collet
999a8488f6
removed test that might be optimized away
...
under UB rule "no overflow on int"
2018-05-02 13:57:33 -07:00
Yann Collet
93cf628a08
introduce LZ4_decoderRingBufferSize()
...
fuzzer : fix and robustify ring buffer tests
2018-05-02 13:01:04 -07:00
Yann Collet
41ad238bf9
Merge pull request #515 from svpv/refactorDec
...
lz4.c: refactor the decoding routines
2018-04-29 07:41:35 -07:00
Alexey Tourbin
ce4e1389cc
fuzzer.c: enabled ring buffer tests for decompress_fast
...
Ring buffer tests were performed only with LZ4_decompress_safe_continue,
leaving my buggy changes to LZ4_decompress_safe_continue undetected.
The tests are now replicated and performed in a similar manner for both
LZ4_decompress_safe_continue and LZ4_decompress_safe_continue (except
for the small buffer case where only one function can be tested,
because part of the dictionary is overwritten with the output).
I also updated function names in the messages (changed them to the
actual ones). The error was reported for LZ4_decompress_safe(),
which I found misleading.
2018-04-27 07:27:10 +03:00
Yann Collet
b2637ab7b2
Merge pull request #512 from lz4/HC_dict
...
In-place unmutable dictionaries for LZ4HC
2018-04-24 13:18:40 -07:00
Nick Terrell
672799e814
Fix compilation error and assert.
2018-04-23 14:21:02 -07:00
Nick Terrell
bb83cad98f
Fix input size validation edge cases
...
The bug is a read up to 2 bytes past the end of the buffer.
There are three cases for this bug, one for each test case added.
* An empty input causes `token = *ip++` to read one byte too far.
* A one byte input with `(token >> ML_BITS) == RUN_MASK` causes
one extra byte to be read without validation. This could be
combined with the first bug to cause 2 extra bytes to be read.
* The case pointed out in issue #508 , where `ip == iend` at the
beginning of the loop after taking the shortcut.
Benchmarks show no regressions on clang or gcc-7 on both my mac
and devserver.
Fixes #508 .
2018-04-23 13:34:18 -07:00
W. Felix Handte
209c9c29d1
Add Some Simple Fuzzer Tests
2018-04-20 15:16:41 -04:00
Yann Collet
444211d259
edited a few traces for debugging
2018-04-16 17:16:08 -07:00
Yann Collet
4aff9b10b5
fixed fuzzer tests
...
which were modified in parallel within branc `dev`
2018-04-16 16:14:28 -07:00
Yann Collet
b5528ac86c
Merge branch 'dev' into lowAddr
2018-04-16 16:12:38 -07:00
W. Felix Handte
9f0f6b89bb
Further Test that ExtDictCtx Mode Produces the Exact Same Output
2018-04-13 11:50:52 -04:00
W. Felix Handte
6dd64e0776
Add Tests for LZ4_attach_dictionary and Friends
2018-04-13 11:50:52 -04:00
test4973
8af32ce6f7
modified a few traces for debug
2018-04-12 13:35:19 -07:00
test4973
ad7e040384
fix minor conversion warning
...
cast from void not implicit for C++
2018-04-09 20:38:00 -07:00
test4973
f9992fa37f
noticed a bug when re-using hash table
...
./fuzzer -vv -s4217 -t7518
2018-04-05 19:09:24 -07:00
test4973
6d931b6a93
fixed lz4 compression starting at small address
...
when using byU32 and byU16 modes
2018-04-05 12:40:33 -07:00
test4973
c3f0ed28ff
added low address fuzzer tests
2018-03-21 07:14:13 -07:00
Yann Collet
20e969e579
fuzzer: added low address compression test
...
is expected to work on linux+gcc only.
2018-02-05 15:19:00 -08:00
Yann Collet
7d2f30c7d1
lz4opt supports _destSize
...
no longer limited to level 9
2017-12-22 12:47:59 +01:00
Yann Collet
fdde4311fb
/tests programs compiled with LZ4_DEBUG=1
...
to enable assert() within /lib
2017-12-22 11:54:43 +01:00
Yann Collet
1025546347
unified HC levels
...
LZ4_setCompressionLevel() can be users accross the whole range of HC levels
No more transition issue between Optimal and HC modes
2017-11-03 11:28:28 -07:00
Yann Collet
0d073d4d28
added extern C
for lz4.h static section
...
should make the file more compatible with C++ compiler, such as Visual or g++
2017-03-17 15:11:09 -07:00
Yann Collet
aae447fffd
LZ4_compress_HC_continue_destSize() works as intended up to level 10
...
It's incompatible with btopt though,
so cLevel >= 11 feature much reduced performance (degraded mode)
2017-03-16 15:41:30 -07:00
Yann Collet
cd35f0d98c
LZ4_compress_HC_destSize() uses LZ4HC_compress_generic() code path
...
Limits compression level to 10,
to remain compatible with Hash Chain.
2017-03-16 15:10:38 -07:00
Yann Collet
430b7d32b3
created LZ4_HC_STATIC_LINKING_ONLY section
...
where are exposed new prototypes *_destSize()
2017-03-16 02:16:24 -07:00
remittor
66b26a389f
tests: fuzzer: Add test for LZ4_compressHC_destSize
2017-03-08 11:13:28 +03:00
Przemyslaw Skibinski
d2b51c22d3
fuzzer: tests more compression levels
2016-12-28 17:47:10 +01:00
Przemyslaw Skibinski
1c80b9af4e
LZ4HC_getSearchNum
2016-12-28 15:18:19 +01:00
Przemyslaw Skibinski
c8b31263cc
added FUZ_CLEVEL_DEFAULT
2016-12-28 13:08:38 +01:00
Przemyslaw Skibinski
973bc79740
util.h and platform.h based on zstd
2016-12-21 16:10:09 +01:00
Przemyslaw Skibinski
3c6ce9c665
fixed gcc 4.4 support
2016-12-21 10:39:27 +01:00
Przemyslaw Skibinski
9546ba62d0
executables use basic types from util.h
2016-12-21 09:44:59 +01:00
Yann Collet
5eb547a608
fix #283 : implement LZ4_versionString().
2016-12-04 20:05:36 +01:00
Yann Collet
1abecbc33c
fix 32-bits mode.
...
Large File support for Mac OS-X in 32-bits mode
Fixed potential undefined behavior
Changed makefile for 32-bits mode
2016-11-17 13:02:06 -08:00
Yann Collet
201149f8eb
fixed conversion warnings
2016-11-14 10:16:11 -08:00
Yann Collet
1b24cc1155
fixed conversion warnings
2016-11-14 07:10:31 -08:00
Yann Collet
ecc55d19ba
fixed uintptr_t on pre-c99 compilers
2016-11-13 21:06:38 -08:00
Yann Collet
d5c9b39ddd
minor code refactoring
2016-11-13 20:50:58 -08:00
Yann Collet
84b97f90b8
fuzzer code refactoring
...
fix g++ conversion warning
2016-11-12 17:14:57 -08:00
Yann Collet
cb2230826b
fixed fuzzer error
2016-11-12 10:09:59 -08:00
Yann Collet
3580d96980
enabled deprecation warnings on remaining obsolete functions
2016-11-12 08:48:42 -08:00
Przemyslaw Skibinski
84cedb4632
updated links to LZ4 repository
2016-11-03 15:12:57 +01:00
Przemyslaw Skibinski
e624978ea2
test programs moved to tests/
2016-11-03 15:03:43 +01:00