diff options
author | Junio C Hamano <gitster@pobox.com> | 2024-12-30 15:50:28 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2024-12-30 15:50:28 +0100 |
commit | cade724b527d753def6b2cd169df62ef03bdbfe2 (patch) | |
tree | b202c56abb0a9c3b7d575963fa1d305ed4d91ae6 | |
parent | Merge branch 'ps/meson-test-wo-gitweb' (diff) | |
parent | ci: exercise unsafe OpenSSL backend (diff) | |
download | git-cade724b527d753def6b2cd169df62ef03bdbfe2.tar.xz git-cade724b527d753def6b2cd169df62ef03bdbfe2.zip |
Merge branch 'ps/weak-sha1-for-tail-sum-fix' into ps/meson-weak-sha1-build
* ps/weak-sha1-for-tail-sum-fix:
ci: exercise unsafe OpenSSL backend
builtin/fast-import: fix segfault with unsafe SHA1 backend
bulk-checkin: fix segfault with unsafe SHA1 backend
-rw-r--r-- | builtin/fast-import.c | 2 | ||||
-rw-r--r-- | bulk-checkin.c | 2 | ||||
-rwxr-xr-x | ci/run-build-and-tests.sh | 1 |
3 files changed, 3 insertions, 2 deletions
diff --git a/builtin/fast-import.c b/builtin/fast-import.c index 1fa2929a01..0f86392761 100644 --- a/builtin/fast-import.c +++ b/builtin/fast-import.c @@ -1106,7 +1106,7 @@ static void stream_blob(uintmax_t len, struct object_id *oidout, uintmax_t mark) || (pack_size + PACK_SIZE_THRESHOLD + len) < pack_size) cycle_packfile(); - the_hash_algo->init_fn(&checkpoint.ctx); + the_hash_algo->unsafe_init_fn(&checkpoint.ctx); hashfile_checkpoint(pack_file, &checkpoint); offset = checkpoint.offset; diff --git a/bulk-checkin.c b/bulk-checkin.c index 4a70a70a95..433070a3bd 100644 --- a/bulk-checkin.c +++ b/bulk-checkin.c @@ -272,7 +272,7 @@ static int deflate_blob_to_pack(struct bulk_checkin_packfile *state, OBJ_BLOB, size); the_hash_algo->init_fn(&ctx); the_hash_algo->update_fn(&ctx, obuf, header_len); - the_hash_algo->init_fn(&checkpoint.ctx); + the_hash_algo->unsafe_init_fn(&checkpoint.ctx); /* Note: idx is non-NULL when we are writing */ if ((flags & HASH_WRITE_OBJECT) != 0) diff --git a/ci/run-build-and-tests.sh b/ci/run-build-and-tests.sh index c4a41bba0b..76667a1277 100755 --- a/ci/run-build-and-tests.sh +++ b/ci/run-build-and-tests.sh @@ -17,6 +17,7 @@ linux-gcc) export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main ;; linux-TEST-vars) + export OPENSSL_SHA1_UNSAFE=YesPlease export GIT_TEST_SPLIT_INDEX=yes export GIT_TEST_MERGE_ALGORITHM=recursive export GIT_TEST_FULL_IN_PACK_ARRAY=true |