libiwinfo: clear buffer in nl80211_ifname2phy(), prevents running operations against the wrong phy
This commit is contained in:
parent
8fd3c49a13
commit
6f46d97b76
1 changed files with 2 additions and 0 deletions
|
@ -298,6 +298,8 @@ static char * nl80211_ifname2phy(const char *ifname)
|
||||||
static char phy[32] = { 0 };
|
static char phy[32] = { 0 };
|
||||||
struct nl80211_msg_conveyor *req;
|
struct nl80211_msg_conveyor *req;
|
||||||
|
|
||||||
|
memset(phy, 0, sizeof(phy));
|
||||||
|
|
||||||
req = nl80211_msg(ifname, NL80211_CMD_GET_WIPHY, 0);
|
req = nl80211_msg(ifname, NL80211_CMD_GET_WIPHY, 0);
|
||||||
if (req)
|
if (req)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue