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

Side by Side Diff: net/proxy/proxy_service_v8.cc

Issue 2259823002: Re-write many calls to WrapUnique() with MakeUnique() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "net/proxy/proxy_service_v8.h" 5 #include "net/proxy/proxy_service_v8.h"
6 6
7 #include <memory> 7 #include <memory>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 16 matching lines...) Expand all
27 HostResolver* host_resolver, 27 HostResolver* host_resolver,
28 NetLog* net_log, 28 NetLog* net_log,
29 NetworkDelegate* network_delegate) { 29 NetworkDelegate* network_delegate) {
30 DCHECK(proxy_config_service); 30 DCHECK(proxy_config_service);
31 DCHECK(proxy_script_fetcher); 31 DCHECK(proxy_script_fetcher);
32 DCHECK(dhcp_proxy_script_fetcher); 32 DCHECK(dhcp_proxy_script_fetcher);
33 DCHECK(host_resolver); 33 DCHECK(host_resolver);
34 34
35 std::unique_ptr<ProxyService> proxy_service(new ProxyService( 35 std::unique_ptr<ProxyService> proxy_service(new ProxyService(
36 std::move(proxy_config_service), 36 std::move(proxy_config_service),
37 base::WrapUnique(new ProxyResolverFactoryV8TracingWrapper( 37 base::MakeUnique<ProxyResolverFactoryV8TracingWrapper>(
38 host_resolver, net_log, 38 host_resolver, net_log,
39 base::Bind(&NetworkDelegateErrorObserver::Create, network_delegate, 39 base::Bind(&NetworkDelegateErrorObserver::Create, network_delegate,
40 base::ThreadTaskRunnerHandle::Get()))), 40 base::ThreadTaskRunnerHandle::Get())),
41 net_log)); 41 net_log));
42 42
43 // Configure fetchers to use for PAC script downloads and auto-detect. 43 // Configure fetchers to use for PAC script downloads and auto-detect.
44 proxy_service->SetProxyScriptFetchers(proxy_script_fetcher, 44 proxy_service->SetProxyScriptFetchers(proxy_script_fetcher,
45 std::move(dhcp_proxy_script_fetcher)); 45 std::move(dhcp_proxy_script_fetcher));
46 46
47 return proxy_service; 47 return proxy_service;
48 } 48 }
49 49
50 } // namespace net 50 } // namespace net
OLDNEW
« no previous file with comments | « net/proxy/proxy_service_unittest.cc ('k') | net/quic/chromium/bidirectional_stream_quic_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698