Now that both hostapd and wpa_supplicant already enforce no duplicate
fst_attach() calls, there is no need for this check within fst_attach().
Signed-off-by: Jouni Malinen <j@w1.fi>
}
-static struct fst_group * fst_find_group_by_iface(const char *ifname)
-{
- struct fst_group *g;
-
- foreach_fst_group(g) {
- if (fst_group_get_iface_by_name(g, ifname))
- return g;
- }
-
- return NULL;
-}
-
-
struct fst_iface * fst_attach(const char *ifname, const u8 *own_addr,
const struct fst_wpa_obj *iface_obj,
const struct fst_iface_cfg *cfg)
WPA_ASSERT(iface_obj != NULL);
WPA_ASSERT(cfg != NULL);
- g = fst_find_group_by_iface(ifname);
- if (g) {
- fst_printf(MSG_ERROR,
- "%s: iface is already part of an FST group: %s",
- ifname, g->group_id);
- return NULL;
- }
-
foreach_fst_group(g) {
if (os_strcmp(cfg->group_id, fst_group_get_id(g)) == 0) {
group = g;