zlib-ng: libgit2 test suite failures with zlib-ng in compat mode
https://github.com/libgit2/libgit2#running-tests
Tested libs:
- ZLIB-NG: 2.1.4 compat mode
- zlib 1.3.0 canonical
Against:
- libgit2 HEAD
- libgit2 1.3.0
- libgit2 1.5.2
- solbuild (via libgit2)
I have found failing tests in the libgit2 testsuite with zlib-ng (compat mode) installed/ld_preloaded. This propagates to applications using libgit2 such as solbuild which will fail to clone repositories with zlib-ng installed. The tests pass as expected with canonical zlib installed. Please let me know if you can replicate.
Rebuilding libgit2 against zlib-ng-devel in compat mode doesn’t seem to resolve the issue.
The following tests fail for me with zlib-ng installed:
1/12 Offline
1) Failure:
pack::packbuilder::create_pack [/home/ninya/libgit2/tests/libgit2/pack/packbuilder.c:143]
String mismatch: hex != "5d410bdf97cf896f9007681b92868471d636954b"
'5f688cedc3a5132f15fc3352a35bc5dcb6a536a4' != '5d410bdf97cf896f9007681b92868471d636954b' (at byte 1)
2) Failure:
pack::packbuilder::get_name [/home/ninya/libgit2/tests/libgit2/pack/packbuilder.c:151]
String mismatch: "7f5fa362c664d68ba7221259be1cbd187434b2f0" != git_packbuilder_name(_packbuilder)
'7f5fa362c664d68ba7221259be1cbd187434b2f0' != 'f120f6bbad709d0e3c021ca8f9d7c26c3882497b' (at byte 0)
3) Failure:
pack::packbuilder::write_default_path [/home/ninya/libgit2/tests/libgit2/pack/packbuilder.c:159]
Expression is not true: git_fs_path_exists("objects/pack/pack-7f5fa362c664d68ba7221259be1cbd187434b2f0.idx")
4) Failure:
pack::packbuilder::permissions_standard [/home/ninya/libgit2/tests/libgit2/pack/packbuilder.c:184]
Function call failed: (stat("pack-7f5fa362c664d68ba7221259be1cbd187434b2f0.idx", &statbuf))
error -1 - no error
5) Failure:
pack::packbuilder::permissions_readonly [/home/ninya/libgit2/tests/libgit2/pack/packbuilder.c:184]
Function call failed: (stat("pack-7f5fa362c664d68ba7221259be1cbd187434b2f0.idx", &statbuf))
error -1 - no error
6) Failure:
pack::packbuilder::permissions_readwrite [/home/ninya/libgit2/tests/libgit2/pack/packbuilder.c:184]
Function call failed: (stat("pack-7f5fa362c664d68ba7221259be1cbd187434b2f0.idx", &statbuf))
error -1 - no error
3/12 Online
1) Failure:
online::clone::can_checkout_a_cloned_repo [/home/ninya/libgit2/tests/libgit2/online/clone.c:243]
Function call failed: (git_clone(&g_repo, "http://github.com/libgit2/TestGitRepository", "./foo", &g_options))
error -1 - error reading from the zlib stream
2) Failure:
online::fetch::doesnt_retrieve_a_pack_when_the_repository_is_up_to_date [/home/ninya/libgit2/tests/libgit2/online/fetch.c:133]
Function call failed: (git_clone(&_repository, "https://github.com/libgit2/TestGitRepository.git", "./fetch/lg2", &opts))
error -1 - error reading from the zlib stream
3) Failure:
online::shallow::clone_depth_zero [/home/ninya/libgit2/tests/libgit2/online/shallow.c:27]
Function call failed: (git_clone(&repo, "https://github.com/libgit2/TestGitRepository", git_str_cstr(&path), &clone_opts))
error -1 - error reading from the zlib stream
4/12 online_customcert
1) Failure:
online::customcert::file [/home/ninya/libgit2/tests/libgit2/online/customcert.c:68]
Function call failed: (git_clone(&g_repo, "https://test.libgit2.org:1443/anonymous/test.git", "./cloned", ((void *)0)))
error -1 - error reading from the zlib stream
2) Failure:
online::customcert::path [/home/ninya/libgit2/tests/libgit2/online/customcert.c:76]
Function call failed: (git_clone(&g_repo, "https://test.libgit2.org:2443/anonymous/test.git", "./cloned", ((void *)0)))
error -1 - error reading from the zlib stream
About this issue
- Original URL
- State: closed
- Created 8 months ago
- Comments: 54 (42 by maintainers)
Commits related to this issue
- Fix an issue with regard to finishing out the window Evidently we weren't hitting this code path very often in our tests? If we reach here, there are some circumstances where we never ran any of the ... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window Evidently we weren't hitting this code path very often in our tests? If we reach here, there are some circumstances where we never ran any of the ... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window Evidently we weren't hitting this code path very often in our tests? If we reach here, there are some circumstances where we never ran any of the ... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window Evidently we weren't hitting this code path very often in our tests? If we reach here, there are some circumstances where we never ran any of the ... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window Evidently we weren't hitting this code path very often in our tests? If we reach here, there are some circumstances where we never ran any of the ... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window Evidently we weren't hitting this code path very often in our tests? If we reach here, there are some circumstances where we never ran any of the ... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window Evidently we weren't hitting this code path very often in our tests? If we reach here, there are some circumstances where we never ran any of the ... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window if inflate is invoked with Z_FINISH, and it deems a window was not necessary, there's a corner case where we never checksum the bytes. Detect this... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window if inflate is invoked with Z_FINISH, and it deems a window was not necessary, there's a corner case where we never checksum the bytes. Detect this... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window if inflate is invoked with Z_FINISH, and it deems a window was not necessary, there's a corner case where we never checksum the bytes. Detect this... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window if inflate is invoked with Z_FINISH, and it deems a window was not necessary, there's a corner case where we never checksum the bytes. Detect this... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window if inflate is invoked with Z_FINISH, and it deems a window was not necessary, there's a corner case where we never checksum the bytes. Detect this... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window if inflate is invoked with Z_FINISH, and it deems a window was not necessary, there's a corner case where we never checksum the bytes. Detect this... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window if inflate is invoked with Z_FINISH, and it deems a window was not necessary, there's a corner case where we never checksum the bytes. Detect this... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window if inflate is invoked with Z_FINISH, and it deems a window was not necessary, there's a corner case where we never checksum the bytes. Detect this... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window if inflate is invoked with Z_FINISH, and it deems a window was not necessary, there's a corner case where we never checksum the bytes. Detect this... — committed to KungFuJesus/zlib-ng by KungFuJesus 7 months ago
- Fix an issue with regard to finishing out the window if inflate is invoked with Z_FINISH, and it deems a window was not necessary, there's a corner case where we never checksum the bytes. Detect this... — committed to zlib-ng/zlib-ng by KungFuJesus 7 months ago
Yeah I’m marking it as a draft. I think I know what I need to do to fix it, though.
Resolved for me. Thanks for the work!
So I think I might have it. Strangely it requires minigzip, though.
Hmm, well I’ve reproduced it, at least with LD_PRELOAD. I’ll build with the headers and do a more thorough debugging effort soon.
To clarify, the above partial revert permanently fixed it for you? Not sporadically?