From c2597504e01992fd5a39aa3bff3a93a807438293 Mon Sep 17 00:00:00 2001 From: wangmingrong Date: Tue, 21 Nov 2023 20:48:23 +0800 Subject: [PATCH] nsh: Fix PS printing misalignment When the stack is allocated in megabytes, printing seven bits of ps will not align Signed-off-by: wangmingrong --- nshlib/nsh_proccmds.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nshlib/nsh_proccmds.c b/nshlib/nsh_proccmds.c index 859d0b808b..ab02f38f50 100644 --- a/nshlib/nsh_proccmds.c +++ b/nshlib/nsh_proccmds.c @@ -534,10 +534,10 @@ static int ps_callback(FAR struct nsh_vtbl_s *vtbl, FAR const char *dirpath, "%08lu " #endif #ifdef PS_SHOW_STACKSIZE - "%06lu " + "%07lu " #endif #ifdef PS_SHOW_STACKUSAGE - "%06lu " + "%07lu " "%3lu.%lu%%%c " #endif #ifdef NSH_HAVE_CPULOAD