Description of problem: As approx a month ago, libgit2 crashes when cloning https repositories. It happens in F30 and F31, but not F32. Version-Release number of selected component (if applicable): libgit2-devel-0.28.4-2.fc31.x86_64 How reproducible: Every time Steps to Reproduce: below an example program. #include <git2.h> #include <stdlib.h> #include <stdio.h> int main(){ git_libgit2_init(); git_repository *repo = NULL; int err = git_clone(&repo, "https://github.com/ropensci/antiword", "antiword", NULL); if (err < 0) { const git_error *e = git_error_last(); printf("Error %d/%d: %s\n", err, e->klass, e->message); exit(err); } return 0; } Compile with: gcc test.c -lgit2 Actual results: crash Expected results: cloned repository Additional info: gdb suggests the problem may be related to libhttp-parser. Backtrace: Program received signal SIGSEGV, Segmentation fault. 0x00007fa6a629e9f8 in on_header_field () from /lib64/libgit2.so.28 Missing separate debuginfos, use: dnf debuginfo-install http-parser-2.9.3-1.fc31.x86_64 libgit2-0.28.4-2.fc31.x86_64 libssh2-1.9.0-3.fc31.x86_64 openssl-libs-1.1.1d-2.fc31.x86_64 zlib-1.2.11-20.fc31.x86_64 (gdb) bt #0 0x00007fa6a629e9f8 in on_header_field () from /lib64/libgit2.so.28 #1 0x00007fa6a5c8b1a2 in http_parser_execute () from /lib64/libhttp_parser.so.2 #2 0x00007fa6a62a083a in http_stream_read () from /lib64/libgit2.so.28 #3 0x00007fa6a62a1f05 in git_smart.recv_cb () from /lib64/libgit2.so.28 #4 0x00007fa6a62a40d0 in git_smart.store_refs () from /lib64/libgit2.so.28 #5 0x00007fa6a62a2693 in git_smart.connect () from /lib64/libgit2.so.28 #6 0x00007fa6a62810b0 in git_remote.connect () from /lib64/libgit2.so.28 #7 0x00007fa6a6282a52 in git_remote_fetch () from /lib64/libgit2.so.28 #8 0x00007fa6a622188f in git_clone () from /lib64/libgit2.so.28 #9 0x000000000040119d in main (argc=1, argv=0x7ffca2e16378) at test.c:8
Moving to http-parser.
Turns out http-parser 2.9.3 silently changed ABI. Simply rebuilding libgit2 against http-parser 2.9.3 fixes it.
FEDORA-2020-5abc1db666 has been submitted as an update to Fedora 31. https://bodhi.fedoraproject.org/updates/FEDORA-2020-5abc1db666
libgit2-0.27.8-3.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2020-6dcbc5d22b
libgit2-0.28.4-3.fc31 has been pushed to the Fedora 31 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2020-5abc1db666
libgit2-0.28.4-3.fc31 has been pushed to the Fedora 31 stable repository. If problems still persist, please make note of it in this bug report.
FEDORA-2020-6dcbc5d22b has been pushed to the Fedora 30 stable repository. If problem still persists, please make note of it in this bug report.