diff options
author | android-build-team Robot <android-build-team-robot@google.com> | 2019-12-12 02:10:11 +0000 |
---|---|---|
committer | android-build-team Robot <android-build-team-robot@google.com> | 2019-12-12 02:10:11 +0000 |
commit | 5382002c37d7d82f1be6c74928dcc5d76d89590d (patch) | |
tree | 4798320c37c6c6fb91373b2e439d962665abd41e | |
parent | 7c8eaef08933047c5115b2bd7cdb4afa9ce5616b (diff) | |
parent | eee89435cb5f722da6a4298d9fa19144f5bcdf10 (diff) | |
download | wpa_supplicant_8-5382002c37d7d82f1be6c74928dcc5d76d89590d.tar.gz |
Snap for 6066307 from eee89435cb5f722da6a4298d9fa19144f5bcdf10 to qt-qpr2-release
Change-Id: I38d1a1de33404009fd8121102f8b877a31f4a4c9
-rw-r--r-- | wpa_supplicant/hidl/1.2/p2p_iface.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/wpa_supplicant/hidl/1.2/p2p_iface.cpp b/wpa_supplicant/hidl/1.2/p2p_iface.cpp index 4df65aa1..0a6b657d 100644 --- a/wpa_supplicant/hidl/1.2/p2p_iface.cpp +++ b/wpa_supplicant/hidl/1.2/p2p_iface.cpp @@ -1634,6 +1634,10 @@ SupplicantStatus P2pIface::addGroup_1_2Internal( int vht = wpa_s->conf->p2p_go_vht; int ht40 = wpa_s->conf->p2p_go_ht40 || vht; + if (wpa_s->global->p2p == NULL) { + return {SupplicantStatusCode::FAILURE_IFACE_DISABLED, ""}; + } + if (!isSsidValid(ssid)) { return {SupplicantStatusCode::FAILURE_ARGS_INVALID, "SSID is invalid."}; } @@ -1643,10 +1647,6 @@ SupplicantStatus P2pIface::addGroup_1_2Internal( } if (!joinExistingGroup) { - if (wpa_s->global->p2p == NULL) { - return {SupplicantStatusCode::FAILURE_IFACE_DISABLED, ""}; - } - struct p2p_data *p2p = wpa_s->global->p2p; os_memcpy(p2p->ssid, ssid.data(), ssid.size()); p2p->ssid_len = ssid.size(); |