diff options
| author | John Hubbard <[email protected]> | 2023-06-06 00:16:32 -0700 |
|---|---|---|
| committer | Andrew Morton <[email protected]> | 2023-06-19 16:19:02 -0700 |
| commit | 0e14e7e9f16ffe8f0761bc627829e8bd1cb32793 (patch) | |
| tree | c5589a0dc0c0473881e077d6529d461f11af42bf /tools/perf/scripts/python/bin | |
| parent | 7bddd2263e3781429f72f05e59fdf5e531e0bf26 (diff) | |
selftests/mm: fix two -Wformat-security warnings in uffd builds
The uffd tests generate two compile time warnings from clang's
-Wformat-security setting. These trigger at the call sites for
uffd_test_start() and uffd_test_skip().
1) Fix the uffd_test_start() issue by removing the intermediate
test_name variable (thanks to David Hildenbrand for showing how to do
this).
2) Fix the uffd_test_skip() issue by observing that there is no need for
a macro and a variable args approach, because all callers of
uffd_test_skip() pass in a simple char* string, without any format
specifiers. So just change uffd_test_skip() into a regular C function.
Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: John Hubbard <[email protected]>
Reviewed-by: David Hildenbrand <[email protected]>
Reviewed-by: Peter Xu <[email protected]>
Tested-by: Muhammad Usama Anjum <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Nathan Chancellor <[email protected]>
Cc: Shuah Khan <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/bin')
0 files changed, 0 insertions, 0 deletions