From 56f2a689a2016ba2ae9cc40833447dff648af809 Mon Sep 17 00:00:00 2001 From: Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> Date: Mon, 8 Sep 2025 18:32:24 +0100 Subject: [PATCH] ci: Do not patch `leveldb` to workaround UB in "tidy" CI job --- ci/test/03_test_script.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/ci/test/03_test_script.sh b/ci/test/03_test_script.sh index 05e4d8fd54a..3e07f1c86d2 100755 --- a/ci/test/03_test_script.sh +++ b/ci/test/03_test_script.sh @@ -41,7 +41,10 @@ echo "=== BEGIN env ===" env echo "=== END env ===" -( +# Don't apply patches in the tidy job, because it relies on the `git diff` +# command to detect IWYU errors. It is safe to skip this patch in the tidy job +# because it doesn't run a UB detector. +if [ "$RUN_TIDY" != "true" ]; then # compact->outputs[i].file_size is uninitialized memory, so reading it is UB. # The statistic bytes_written is only used for logging, which is disabled in # CI, so as a temporary minimal fix to work around UB and CI failures, leave @@ -62,7 +65,7 @@ echo "=== END env ===" mutex_.Lock(); stats_[compact->compaction->level() + 1].Add(stats); EOF -) +fi if [ "$RUN_FUZZ_TESTS" = "true" ]; then export DIR_FUZZ_IN=${DIR_QA_ASSETS}/fuzz_corpora/