lkml.org 
[lkml]   [2024]   [Jan]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH v1 1/2] selftest: breakpoints: fix a minor typo in the format string
Date
GCC 13.2.0 reported a format string warning:

step_after_suspend_test.c: In function ‘run_test’:
step_after_suspend_test.c:92:32: warning: too many arguments for format [-Wformat-extra-args]
92 | ksft_print_msg("waitpid() failed: $s\n", strerror(errno));
| ^~~~~~~~~~~~~~~~~~~~~~~~

Fixing the typo $s into %s resolves the issue.

Fixes: 3fa72f2c784b5 ("selftests: breakpoints: step_after_suspend_test use ksft_* var arg msg api")
Cc: Shuah Khan <shuah@kernel.org>
Cc: linux-kselftest@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Mirsad Todorovac <mirsad.todorovac@alu.unizg.hr>
---
tools/testing/selftests/breakpoints/step_after_suspend_test.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/testing/selftests/breakpoints/step_after_suspend_test.c b/tools/testing/selftests/breakpoints/step_after_suspend_test.c
index 2cf6f10ab7c4..b8703c499d28 100644
--- a/tools/testing/selftests/breakpoints/step_after_suspend_test.c
+++ b/tools/testing/selftests/breakpoints/step_after_suspend_test.c
@@ -89,7 +89,7 @@ int run_test(int cpu)

wpid = waitpid(pid, &status, __WALL);
if (wpid != pid) {
- ksft_print_msg("waitpid() failed: $s\n", strerror(errno));
+ ksft_print_msg("waitpid() failed: %s\n", strerror(errno));
return KSFT_FAIL;
}
if (WIFEXITED(status)) {
--
2.40.1

\
 
 \ /
  Last update: 2024-01-09 22:58    [W:0.022 / U:0.232 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site