Skip to content

Commit

Permalink
px4io: fix argv index & avoid empty 'unknown argument: ' warning
Browse files Browse the repository at this point in the history
  • Loading branch information
bkueng committed Feb 6, 2020
1 parent be1072e commit 4f9071d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/drivers/px4io/px4io.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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]);
}
}

Expand Down

0 comments on commit 4f9071d

Please sign in to comment.