mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-17 06:33:35 +08:00
px4io: fix argv index & avoid empty 'unknown argument: ' warning
This commit is contained in:
@@ -3012,8 +3012,8 @@ start(int argc, char *argv[])
|
||||
} else if (!strcmp(argv[extra_args], "hil")) {
|
||||
hitl_mode = true;
|
||||
|
||||
} else {
|
||||
warnx("unknown argument: %s", argv[1]);
|
||||
} else if (argv[extra_args][0] != '\0') {
|
||||
PX4_WARN("unknown argument: %s", argv[extra_args]);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user