mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-24 13:43:28 +00:00
cmd: ubi: Fix 'ubi list' command arguments parsing
This fixes allowed argc variable value for arguments parsing
Fixes: 6de1daf64b
("cmd: ubi: Add 'ubi list' command")
Signed-off-by: Dmitry Dunaev <dunaev@tecon.ru>
This commit is contained in:
parent
832148f675
commit
34031e9cce
1 changed files with 1 additions and 1 deletions
|
@ -653,7 +653,7 @@ static int do_ubi(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[])
|
|||
|
||||
if (strcmp(argv[1], "list") == 0) {
|
||||
int numeric = 0;
|
||||
if (argc >= 2 && argv[2][0] == '-') {
|
||||
if (argc >= 3 && argv[2][0] == '-') {
|
||||
if (strcmp(argv[2], "-numeric") == 0)
|
||||
numeric = 1;
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue