File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change 45
45
/* Help command summary layout */
46
46
47
47
#define HELP_LINELEN 80
48
+ #define HELP_TABSIZE 4
48
49
#define NUM_CMDS ((sizeof(g_cmdmap)/sizeof(struct cmdmap_s)) - 1)
49
50
50
51
/****************************************************************************
@@ -616,7 +617,10 @@ static inline void help_cmdlist(FAR struct nsh_vtbl_s *vtbl)
616
617
unsigned int j ;
617
618
unsigned int k ;
618
619
unsigned int offset ;
619
- char line [HELP_LINELEN ];
620
+
621
+ /* Extra 5 bytes for tab before newline and '\0' */
622
+
623
+ char line [HELP_LINELEN + HELP_TABSIZE + 1 ];
620
624
621
625
/* Pick an optimal column width */
622
626
@@ -654,7 +658,7 @@ static inline void help_cmdlist(FAR struct nsh_vtbl_s *vtbl)
654
658
{
655
659
/* Tab before a new line */
656
660
657
- offset = 4 ;
661
+ offset = HELP_TABSIZE ;
658
662
memset (line , ' ' , offset );
659
663
660
664
for (j = 0 , k = i ;
You can’t perform that action at this time.
0 commit comments