From: kw0619.kim Date: Thu, 7 Nov 2019 10:19:28 +0000 (+0900) Subject: wlbt: return SUCCESS when num_bssid is 0 X-Git-Tag: MMI-RSA31.Q1-48-36-11~4 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=60a60ab054bd95a70874938ae1380f6db2340ac2;p=GitHub%2FMotorolaMobilityLLC%2Fhardware-samsung_slsi-scsc_wifibt-wifi_hal.git wlbt: return SUCCESS when num_bssid is 0 VTS is failed when maximum blacklist is zero. If max blacklist is zero, return SUCCESS SCSC-Bug-Id: HOST-11403 Change-Id: Ic9c56570c947df87cd6d37b3697a65cbcb41fa6e Signed-off-by: kw0619.kim --- diff --git a/roam.cpp b/roam.cpp index 0993ec7..1d79b9d 100755 --- a/roam.cpp +++ b/roam.cpp @@ -205,13 +205,17 @@ wifi_error wifi_configure_roaming(wifi_interface_handle iface, wifi_roaming_conf if (!roaming_config) { ALOGE("%s: Invalid Buffer provided. Exit", __FUNCTION__); return WIFI_ERROR_INVALID_ARGS; - } + } /* Generate request id randomly*/ - requestId = get_requestid(); - bssid_params.num_bssid = roaming_config->num_blacklist_bssid; + requestId = get_requestid(); + bssid_params.num_bssid = roaming_config->num_blacklist_bssid; + + if (bssid_params.num_bssid == 0) { + return WIFI_SUCCESS; + } - memcpy(bssid_params.bssids, roaming_config->blacklist_bssid, + memcpy(bssid_params.bssids, roaming_config->blacklist_bssid, (bssid_params.num_bssid * sizeof(mac_addr))); ret = wifi_set_bssid_blacklist(requestId, iface, bssid_params);