return 0;
}
-_public_ int sd_machine_get_ifindexes(const char *machine, int **ifindexes) {
+_public_ int sd_machine_get_ifindices(const char *machine, int **ifindices) {
_cleanup_free_ char *netif = NULL;
size_t l, allocated = 0, nr = 0;
char *w, *state;
int r;
assert_return(machine_name_is_valid(machine), -EINVAL);
- assert_return(ifindexes, -EINVAL);
+ assert_return(ifindices, -EINVAL);
p = strappenda("/run/systemd/machines/", machine);
r = parse_env_file(p, NEWLINE, "NETIF", &netif, NULL);
if (r < 0)
return r;
if (!netif) {
- *ifindexes = NULL;
+ *ifindices = NULL;
return 0;
}
ni[nr++] = ifi;
}
- *ifindexes = ni;
+ *ifindices = ni;
return nr;
}