fix: address re-review — coverage build, chunk OOB guard, UBSan loads, srand scope
CI / lint (push) Successful in 7s
CI / lint (pull_request) Successful in 7s
CI / sanitizers (address) (push) Successful in 14s
CI / sanitizers (undefined) (push) Successful in 15s
CI / fuzz-build (push) Successful in 12s
CI / coverage (push) Successful in 10s
CI / build-and-test (push) Successful in 55s
CI / valgrind (push) Successful in 12s
CI / sanitizers (address) (pull_request) Successful in 14s
CI / sanitizers (undefined) (pull_request) Successful in 14s
CI / fuzz-build (pull_request) Successful in 14s
CI / build-and-test (pull_request) Successful in 55s
CI / coverage (pull_request) Failing after 8s
CI / valgrind (pull_request) Successful in 11s

- Remove -DSTRICT_WARNINGS=ON from coverage job (_FORTIFY_SOURCE + -O0 + -Werror fatal)
- Fix chunk.c metadata guard: peek at present flag before calling metadata_from_buf
  so the remaining_size check covers the full sizeof(int)+FILE_METADATA_WIRE_SIZE
- Fix chunk.c UBSan misaligned loads: use memcpy instead of *(size_t*)deref
- Move srand(42) to test_property() top level so all property tests are seeded
This commit is contained in:
2026-07-20 14:27:20 +02:00
parent ed6242cfc5
commit d6dcc60492
3 changed files with 15 additions and 13 deletions
+1 -1
View File
@@ -20,7 +20,6 @@ static Data* random_data(int min_size, int max_size) {
}
static void test_property_compress_roundtrip() {
srand(42);
for (int iter = 0; iter < 10; iter++) {
Data* original = random_data(1, 10000);
EXPECT_NOT_NULL(original);
@@ -114,6 +113,7 @@ static void test_property_chunk_roundtrip() {
}
void test_property() {
srand(42);
test_property_compress_roundtrip();
test_property_delta_roundtrip();
test_property_chunk_roundtrip();