diff options
author | guoyin.chen <guoyin.chen@freescale.com> | 2016-05-07 00:12:35 +0000 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2016-05-07 00:12:35 +0000 |
commit | 35ddc6b045984ce3178043eb156179dcb49fa8d1 (patch) | |
tree | 2948b91552ee7cf083f0de1ca958e427843969ea | |
parent | 8fe01e1f6c02b66845a61bc7193deffc140b2b8f (diff) | |
parent | 9f450c918a39099a159384c5bc691d3e9937dafb (diff) | |
download | weaved-35ddc6b045984ce3178043eb156179dcb49fa8d1.tar.gz |
Add check for the selected_service before calling GetProperties am: e477f1e5fd
am: 9f450c918a
* commit '9f450c918a39099a159384c5bc691d3e9937dafb':
Add check for the selected_service before calling GetProperties
Change-Id: I86191a1bd659df5ac03b787ae42e9e340c087c75
-rw-r--r-- | buffet/shill_client.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/buffet/shill_client.cc b/buffet/shill_client.cc index 8e6e1e9..afaebba 100644 --- a/buffet/shill_client.cc +++ b/buffet/shill_client.cc @@ -219,8 +219,10 @@ void ShillClient::StopAccessPoint() { std::string ShillClient::GetConnectedSsid() const { for (const auto& kv : devices_) { VariantDictionary properties; - if (!kv.second.selected_service->GetProperties(&properties, nullptr)) + if (kv.second.selected_service && + (!kv.second.selected_service->GetProperties(&properties, nullptr))) { continue; + } auto property_it = properties.find(shill::kWifiHexSsid); if (property_it == properties.end()) continue; |