summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNingyuan Wang <nywang@google.com>2016-10-11 18:42:12 (GMT)
committerJessica Wagantall <jwagantall@cyngn.com>2016-12-12 19:58:00 (GMT)
commit7cbe254c274d115800a051a7ce6d20f2936c7b1e (patch)
tree063a6595c63fe753f1bdde4049076d5e39e7d23b
parentd6b4e6279ed4688220940de63249525df854fa61 (diff)
downloadandroid_frameworks_opt_net_wifi-7cbe254c274d115800a051a7ce6d20f2936c7b1e.zip
android_frameworks_opt_net_wifi-7cbe254c274d115800a051a7ce6d20f2936c7b1e.tar.gz
android_frameworks_opt_net_wifi-7cbe254c274d115800a051a7ce6d20f2936c7b1e.tar.bz2
resolve merge conflicts of 849c5c7 to mnc-dev
This resovles the merge conflict for ag/1514448/ After Android M, this function uses num_bssid instead of num_ap. Both are prone to stack overflow attacks. CYNGNOS-3312 Bug: 31856351 Test: compile, unit tests, manual test Change-Id: I194850a4c79ddf478d98e750f65b24e82d99ebc0 (cherry picked from commit c579cce67bbb8d0a64b58b3b89d53ae1bce330e9)
-rw-r--r--service/jni/com_android_server_wifi_WifiNative.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/service/jni/com_android_server_wifi_WifiNative.cpp b/service/jni/com_android_server_wifi_WifiNative.cpp
index 1ed21b8..3242888 100644
--- a/service/jni/com_android_server_wifi_WifiNative.cpp
+++ b/service/jni/com_android_server_wifi_WifiNative.cpp
@@ -892,7 +892,7 @@ static jboolean android_net_wifi_setHotlist(
return false;
}
- if (params.num_ap >
+ if (params.num_bssid >
static_cast<int>(sizeof(params.ap) / sizeof(params.ap[0]))) {
ALOGE("setHotlist array length is too long");
android_errorWriteLog(0x534e4554, "31856351");