From: Jouni Malinen Date: Sun, 26 Apr 2015 12:58:10 +0000 (+0300) Subject: Make VLAN ID available in STA info over control interface X-Git-Tag: hostap_2_5~795 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=87b5b5395993e7c1f223a238da761e9ec753550b;p=thirdparty%2Fhostap.git Make VLAN ID available in STA info over control interface If hostapd has bound a STA into a specific VLAN, the new vlan_id parameter in the control interface STA command can now be used to check which VLAN ID is in use. Signed-off-by: Jouni Malinen --- diff --git a/src/ap/ctrl_iface_ap.c b/src/ap/ctrl_iface_ap.c index 41ab98827..60afcb082 100644 --- a/src/ap/ctrl_iface_ap.c +++ b/src/ap/ctrl_iface_ap.c @@ -153,6 +153,13 @@ static int hostapd_ctrl_iface_sta_mib(struct hostapd_data *hapd, } #endif /* CONFIG_SAE */ + if (sta->vlan_id > 0) { + res = os_snprintf(buf + len, buflen - len, "vlan_id=%d\n", + sta->vlan_id); + if (!os_snprintf_error(buflen - len, res)) + len += res; + } + return len; }