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

Side by Side Diff: components/net_log/chrome_net_log.cc

Issue 1548203002: Convert Pass()→std::move() in //components/[n-z]* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix bad headers Created 4 years, 11 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 "components/net_log/chrome_net_log.h" 5 #include "components/net_log/chrome_net_log.h"
6 6
7 #include <stdio.h> 7 #include <stdio.h>
8 #include <utility>
8 9
9 #include "base/command_line.h" 10 #include "base/command_line.h"
10 #include "base/files/scoped_file.h" 11 #include "base/files/scoped_file.h"
11 #include "base/logging.h" 12 #include "base/logging.h"
12 #include "base/strings/stringprintf.h" 13 #include "base/strings/stringprintf.h"
13 #include "base/sys_info.h" 14 #include "base/sys_info.h"
14 #include "base/values.h" 15 #include "base/values.h"
15 #include "build/build_config.h" 16 #include "build/build_config.h"
16 #include "components/data_reduction_proxy/core/common/data_reduction_proxy_event _store.h" 17 #include "components/data_reduction_proxy/core/common/data_reduction_proxy_event _store.h"
17 #include "components/net_log/net_log_temp_file.h" 18 #include "components/net_log/net_log_temp_file.h"
(...skipping 29 matching lines...) Expand all
47 if (!file) { 48 if (!file) {
48 LOG(ERROR) << "Could not open file " << log_file.value() 49 LOG(ERROR) << "Could not open file " << log_file.value()
49 << " for net logging"; 50 << " for net logging";
50 } else { 51 } else {
51 scoped_ptr<base::Value> constants( 52 scoped_ptr<base::Value> constants(
52 GetConstants(command_line_string, channel_string)); 53 GetConstants(command_line_string, channel_string));
53 write_to_file_observer_.reset(new net::WriteToFileNetLogObserver()); 54 write_to_file_observer_.reset(new net::WriteToFileNetLogObserver());
54 55
55 write_to_file_observer_->set_capture_mode(log_file_mode); 56 write_to_file_observer_->set_capture_mode(log_file_mode);
56 57
57 write_to_file_observer_->StartObserving(this, file.Pass(), 58 write_to_file_observer_->StartObserving(this, std::move(file),
58 constants.get(), nullptr); 59 constants.get(), nullptr);
59 } 60 }
60 } 61 }
61 62
62 trace_net_log_observer_.reset(new net::TraceNetLogObserver()); 63 trace_net_log_observer_.reset(new net::TraceNetLogObserver());
63 trace_net_log_observer_->WatchForTraceStart(this); 64 trace_net_log_observer_->WatchForTraceStart(this);
64 } 65 }
65 66
66 ChromeNetLog::~ChromeNetLog() { 67 ChromeNetLog::~ChromeNetLog() {
67 net_log_temp_file_.reset(); 68 net_log_temp_file_.reset();
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 constants_dict->Set("clientInfo", dict); 102 constants_dict->Set("clientInfo", dict);
102 103
103 data_reduction_proxy::DataReductionProxyEventStore::AddConstants( 104 data_reduction_proxy::DataReductionProxyEventStore::AddConstants(
104 constants_dict.get()); 105 constants_dict.get());
105 } 106 }
106 107
107 return constants_dict.release(); 108 return constants_dict.release();
108 } 109 }
109 110
110 } // namespace net_log 111 } // namespace net_log
OLDNEW
« no previous file with comments | « components/navigation_interception/intercept_navigation_throttle_unittest.cc ('k') | components/net_log/net_log_temp_file.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698