shell: Fix case when too many arguments are provided
Shell was accepting CONFIG_SHELL_ARGC_MAX+1 arguments which lead to memory corruption and fault. Added error message reported when number of provided arguments exceeds CONFIG_SHELL_ARGC_MAX. Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
This commit is contained in:
parent
1c3fd85c94
commit
770f232a67
3 changed files with 15 additions and 8 deletions
|
@ -62,8 +62,6 @@ config SHELL_ARGC_MAX
|
|||
default 12
|
||||
help
|
||||
Maximum number of arguments that can build a command.
|
||||
If command is composed of more than defined, argument SHELL_ARGC_MAX
|
||||
and following are passed as one argument in the string.
|
||||
|
||||
config SHELL_WILDCARD
|
||||
bool "Enable wildcard support in shell"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue