proper handling of target config between NVS and dedicated - release

This commit is contained in:
Philippe G
2022-01-26 14:51:08 -08:00
parent 7bfaa05ad2
commit 3d8c3ae776
5 changed files with 49 additions and 50 deletions

View File

@@ -4,7 +4,7 @@
const struct target_s *target_set[] = { &target_muse, NULL };
void target_init(char *target) {
for (int i = 0; target_set[i]; i++) if (strcasestr(target_set[i]->model, target)) {
for (int i = 0; *target && target_set[i]; i++) if (strcasestr(target_set[i]->model, target)) {
target_set[i]->init();
break;
}