1
0
mirror of https://github.com/facebook/zstd.git synced 2025-03-04 16:15:54 +02:00

fixed zlib test

new versions of the library generate a different error code
This commit is contained in:
Yann Collet 2025-01-15 16:31:00 -08:00
parent 43626f1ce0
commit 0b96e6d42a

View File

@ -340,7 +340,7 @@ void test_large_deflate(Byte *compr, uLong comprLen, Byte *uncompr,
/* =========================================================================== /* ===========================================================================
* Test inflate() with large buffers * Test inflate() with large buffers
*/ */
void test_large_inflate(Byte *compr, uLong comprLen, Byte *uncompr, void test_large_inflate(Byte *compr, uLong comprLen, Byte *uncompr,
uLong uncomprLen) { uLong uncomprLen) {
int err; int err;
@ -442,8 +442,8 @@ void test_sync(Byte *compr, uLong comprLen, Byte *uncompr, uLong uncomprLen) {
CHECK_ERR(err, "inflateSync"); CHECK_ERR(err, "inflateSync");
err = inflate(&d_stream, Z_FINISH); err = inflate(&d_stream, Z_FINISH);
if (err != Z_DATA_ERROR) { if (err != Z_STREAM_END) {
fprintf(stderr, "inflate should report DATA_ERROR\n"); fprintf(stderr, "inflate reported %i != %i (Z_STREAM_END)\n", err, Z_STREAM_END);
/* Because of incorrect adler32 */ /* Because of incorrect adler32 */
exit(1); exit(1);
} }