Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(356)

Unified Diff: components/wifi/wifi_service_win.cc

Issue 2809933003: Remove ListValue::Append(raw ptr) on Win (Closed)
Patch Set: Includes Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/wifi/wifi_service_win.cc
diff --git a/components/wifi/wifi_service_win.cc b/components/wifi/wifi_service_win.cc
index 1d5e1617e04445da1063f9ae89d22b5c9d5725e7..b27443d5f658b48b8c8aa10272f0772b3c7380f3 100644
--- a/components/wifi/wifi_service_win.cc
+++ b/components/wifi/wifi_service_win.cc
@@ -10,7 +10,9 @@
#include <stdint.h>
#include <wlanapi.h>
+#include <memory>
#include <set>
+#include <utility>
#include "base/base_paths_win.h"
#include "base/bind.h"
@@ -22,6 +24,7 @@
#include "base/strings/string16.h"
#include "base/strings/string_util.h"
#include "base/strings/utf_string_conversions.h"
+#include "base/values.h"
#include "base/win/registry.h"
#include "components/onc/onc_constants.h"
#include "components/wifi/network_properties.h"
@@ -581,7 +584,7 @@ void WiFiServiceImpl::SetProperties(
existing_properties->MergeDictionary(properties.get());
} else {
connect_properties_.SetWithoutPathExpansion(network_guid,
- properties.release());
+ std::move(properties));
}
}
@@ -630,7 +633,7 @@ void WiFiServiceImpl::CreateNetwork(
tkip_profile->SetString(kProfileXmlKey, tkip_profile_xml);
tkip_profile->SetBoolean(kProfileSharedKey, shared);
created_profiles_.SetWithoutPathExpansion(network_properties.guid,
- tkip_profile.release());
+ std::move(tkip_profile));
}
*network_guid = network_properties.guid;
@@ -656,7 +659,7 @@ void WiFiServiceImpl::GetVisibleNetworks(const std::string& network_type,
++it) {
std::unique_ptr<base::DictionaryValue> network(
it->ToValue(!include_details));
- network_list->Append(network.release());
+ network_list->Append(std::move(network));
}
}
}
« no previous file with comments | « components/policy/core/common/policy_loader_win_unittest.cc ('k') | content/browser/tracing/etw_tracing_agent_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698