remove check of myoptind >= argc because: [bkueng](/bkueng)

Because BATT_SMBUS is using a different structure (the ModuleBase class), and `BATT_SMBUS::task_spawn` is only called for the `start` command. This is the reason why you don't need to check for it in here.
This commit is contained in:
bazooka joe
2019-02-21 09:45:45 +01:00
committed by Beat Küng
parent 7bac0e03de
commit 6ed5ee6865
-5
View File
@@ -134,11 +134,6 @@ int BATT_SMBUS::task_spawn(int argc, char *argv[])
}
}
if (myoptind >= argc) {
print_usage();
return PX4_ERROR;
}
for (unsigned i = 0; i < NUM_BUS_OPTIONS; i++) {
if (!is_running() && (busid == BATT_SMBUS_BUS_ALL || bus_options[i].busid == busid)) {