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

Side by Side Diff: chrome/browser/task_management/providers/child_process_task_provider.cc

Issue 1551503002: Convert Pass()→std::move() in //chrome (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "chrome/browser/task_management/providers/child_process_task_provider.h " 5 #include "chrome/browser/task_management/providers/child_process_task_provider.h "
6 6
7 #include "base/process/process.h" 7 #include "base/process/process.h"
8 #include "base/stl_util.h" 8 #include "base/stl_util.h"
9 #include "chrome/browser/task_management/providers/child_process_task.h" 9 #include "chrome/browser/task_management/providers/child_process_task.h"
10 #include "content/public/browser/browser_child_process_host_iterator.h" 10 #include "content/public/browser/browser_child_process_host_iterator.h"
(...skipping 20 matching lines...) Expand all
31 for (BrowserChildProcessHostIterator itr; !itr.Done(); ++itr) { 31 for (BrowserChildProcessHostIterator itr; !itr.Done(); ++itr) {
32 const ChildProcessData& process_data = itr.GetData(); 32 const ChildProcessData& process_data = itr.GetData();
33 33
34 // Only add processes that have already started, i.e. with valid handles. 34 // Only add processes that have already started, i.e. with valid handles.
35 if (process_data.handle == base::kNullProcessHandle) 35 if (process_data.handle == base::kNullProcessHandle)
36 continue; 36 continue;
37 37
38 child_processes->push_back(process_data); 38 child_processes->push_back(process_data);
39 } 39 }
40 40
41 return child_processes.Pass(); 41 return child_processes;
42 } 42 }
43 43
44 } // namespace 44 } // namespace
45 45
46 ChildProcessTaskProvider::ChildProcessTaskProvider() 46 ChildProcessTaskProvider::ChildProcessTaskProvider()
47 : tasks_by_handle_(), 47 : tasks_by_handle_(),
48 tasks_by_pid_(), 48 tasks_by_pid_(),
49 weak_ptr_factory_(this) { 49 weak_ptr_factory_(this) {
50 } 50 }
51 51
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 153
154 NotifyObserverTaskRemoved(task); 154 NotifyObserverTaskRemoved(task);
155 155
156 // Finally delete the task. 156 // Finally delete the task.
157 tasks_by_handle_.erase(itr); 157 tasks_by_handle_.erase(itr);
158 tasks_by_pid_.erase(task->process_id()); 158 tasks_by_pid_.erase(task->process_id());
159 delete task; 159 delete task;
160 } 160 }
161 161
162 } // namespace task_management 162 } // namespace task_management
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698