diff mbox series

[5/6] selftests/sigaltstack: Fix wrong format specifier

Message ID 613189f12a8c15df7dc725e4b7ed66ffa4b30fb5.1693216959.git.maciej.wieczor-retman@intel.com (mailing list archive)
State Accepted
Commit a8cfb036115cf840978dd9c384a5cf30899e14b2
Headers show
Series Add printf attribute to kselftest functions | expand

Commit Message

Maciej Wieczor-Retman Aug. 28, 2023, 10:49 a.m. UTC
The format specifier inside ksft printing function expects a long
unsigned int but the passed variable is of unsigned int type.

Fix the format specifier so it matches the passed variable.

Signed-off-by: Wieczor-Retman, Maciej <maciej.wieczor-retman@intel.com>
---
 tools/testing/selftests/sigaltstack/sas.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Ilpo Järvinen Aug. 30, 2023, 12:02 p.m. UTC | #1
On Mon, 28 Aug 2023, Wieczor-Retman, Maciej wrote:

> The format specifier inside ksft printing function expects a long
> unsigned int but the passed variable is of unsigned int type.
> 
> Fix the format specifier so it matches the passed variable.
> 
> Signed-off-by: Wieczor-Retman, Maciej <maciej.wieczor-retman@intel.com>
> ---
>  tools/testing/selftests/sigaltstack/sas.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/tools/testing/selftests/sigaltstack/sas.c b/tools/testing/selftests/sigaltstack/sas.c
> index 98d37cb744fb..07227fab1cc9 100644
> --- a/tools/testing/selftests/sigaltstack/sas.c
> +++ b/tools/testing/selftests/sigaltstack/sas.c
> @@ -111,7 +111,7 @@ int main(void)
>  
>  	/* Make sure more than the required minimum. */
>  	stack_size = getauxval(AT_MINSIGSTKSZ) + SIGSTKSZ;
> -	ksft_print_msg("[NOTE]\tthe stack size is %lu\n", stack_size);
> +	ksft_print_msg("[NOTE]\tthe stack size is %u\n", stack_size);
>  
>  	ksft_print_header();
>  	ksft_set_plan(3);

Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
diff mbox series

Patch

diff --git a/tools/testing/selftests/sigaltstack/sas.c b/tools/testing/selftests/sigaltstack/sas.c
index 98d37cb744fb..07227fab1cc9 100644
--- a/tools/testing/selftests/sigaltstack/sas.c
+++ b/tools/testing/selftests/sigaltstack/sas.c
@@ -111,7 +111,7 @@  int main(void)
 
 	/* Make sure more than the required minimum. */
 	stack_size = getauxval(AT_MINSIGSTKSZ) + SIGSTKSZ;
-	ksft_print_msg("[NOTE]\tthe stack size is %lu\n", stack_size);
+	ksft_print_msg("[NOTE]\tthe stack size is %u\n", stack_size);
 
 	ksft_print_header();
 	ksft_set_plan(3);