fix: address review findings — test_scanner cleanup, basename comment
CI / lint (pull_request) Successful in 9s
CI / sanitizers (address) (pull_request) Successful in 15s
CI / sanitizers (undefined) (pull_request) Successful in 15s
CI / coverage (pull_request) Successful in 10s
CI / fuzz-build (pull_request) Successful in 13s
CI / valgrind (pull_request) Successful in 12s
CI / build-and-test (pull_request) Successful in 54s

This commit is contained in:
2026-07-21 14:19:54 +02:00
parent 0cbc873f5c
commit f932a48910
2 changed files with 2 additions and 2 deletions
+2
View File
@@ -23,6 +23,8 @@ static bool is_excluded(const char* path, const Config* config) {
char* path_dup = str_dup(path);
if (!path_dup)
return false;
/* basename(3) may return a pointer into path_dup or a static buffer;
* either way we free path_dup, not fname. */
char* fname = basename(path_dup);
// Check exclude patterns
-2
View File
@@ -248,8 +248,6 @@ static void test_scanner_max_size() {
const char* dir = "test_scan_max";
const char* small = "test_scan_max/small.txt";
const char* large = "test_scan_max/large.txt";
create_test_file(small, "tiny");
create_test_file(large, "this_content_is_longer_than_ten_chars");
mkdir(dir, 0755);
create_test_file(small, "tiny");