DO NOT MERGE - qt-qpr1-dev-plus-aosp-without-vendor@5915889 into stage-aosp-master
Bug: 142003500
Change-Id: I51e66e9dd8b1d841ba0873789013ce0200640333
diff --git a/src/ap/acs.c b/src/ap/acs.c
index 3b45075..ca3b4e1 100644
--- a/src/ap/acs.c
+++ b/src/ap/acs.c
@@ -942,6 +942,12 @@
}
*freq = 0;
+ if (params.freqs == freq) {
+ wpa_printf(MSG_ERROR, "ACS: No available channels found");
+ os_free(params.freqs);
+ return -1;
+ }
+
iface->scan_cb = acs_scan_complete;
wpa_printf(MSG_DEBUG, "ACS: Scanning %d / %d",