From: Wolfgang Date: Thu, 26 Mar 2020 01:15:17 +0000 (-0700) Subject: Fixing a sanitizer lint problem that was breaking some builds. X-Git-Tag: llvmorg-12-init~11092 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=93f7743851b7a01a8c8f54b3753b6e5cd5591e15;p=platform%2Fupstream%2Fllvm.git Fixing a sanitizer lint problem that was breaking some builds. --- diff --git a/compiler-rt/test/tsan/fiber_cleanup.cpp b/compiler-rt/test/tsan/fiber_cleanup.cpp index a9552d3..5550368 100644 --- a/compiler-rt/test/tsan/fiber_cleanup.cpp +++ b/compiler-rt/test/tsan/fiber_cleanup.cpp @@ -26,7 +26,7 @@ long count_memory_mappings() { pid_t my_pid = getpid(); char proc_file_name[128]; - snprintf(proc_file_name, 128, "/proc/%ld/maps", my_pid); + snprintf(proc_file_name, sizeof(proc_file_name), "/proc/%ld/maps", my_pid); FILE *proc_file = fopen(proc_file_name, "r"); long line_count = 0;