ap: Fix return value in hostapd_drv_switch_channel()

The documentation in driver.h state that in case of an error
-1 is returned.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
This commit is contained in:
Ilan Peer 2017-06-08 11:17:54 +03:00 committed by Jouni Malinen
parent 0b6cbc4e64
commit 6d3e24d3e3

View file

@ -276,7 +276,7 @@ static inline int hostapd_drv_switch_channel(struct hostapd_data *hapd,
{
if (hapd->driver == NULL || hapd->driver->switch_channel == NULL ||
hapd->drv_priv == NULL)
return -ENOTSUP;
return -1;
return hapd->driver->switch_channel(hapd->drv_priv, settings);
}