| OLD | NEW |
| 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 "content/browser/browser_child_process_host_impl.h" | 5 #include "content/browser/browser_child_process_host_impl.h" |
| 6 | 6 |
| 7 #include "base/base_switches.h" | 7 #include "base/base_switches.h" |
| 8 #include "base/bind.h" | 8 #include "base/bind.h" |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/files/file_path.h" | 10 #include "base/files/file_path.h" |
| (...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 185 | 185 |
| 186 base::ProcessHandle BrowserChildProcessHostImpl::GetHandle() const { | 186 base::ProcessHandle BrowserChildProcessHostImpl::GetHandle() const { |
| 187 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); | 187 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
| 188 DCHECK(child_process_.get()) | 188 DCHECK(child_process_.get()) |
| 189 << "Requesting a child process handle before launching."; | 189 << "Requesting a child process handle before launching."; |
| 190 DCHECK(child_process_->GetHandle()) | 190 DCHECK(child_process_->GetHandle()) |
| 191 << "Requesting a child process handle before launch has completed OK."; | 191 << "Requesting a child process handle before launch has completed OK."; |
| 192 return child_process_->GetHandle(); | 192 return child_process_->GetHandle(); |
| 193 } | 193 } |
| 194 | 194 |
| 195 void BrowserChildProcessHostImpl::SetNaClDebugStubPort(int port) { |
| 196 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
| 197 data_.nacl_debug_stub_port = port; |
| 198 } |
| 199 |
| 195 void BrowserChildProcessHostImpl::SetName(const base::string16& name) { | 200 void BrowserChildProcessHostImpl::SetName(const base::string16& name) { |
| 196 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); | 201 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
| 197 data_.name = name; | 202 data_.name = name; |
| 198 } | 203 } |
| 199 | 204 |
| 200 void BrowserChildProcessHostImpl::SetHandle(base::ProcessHandle handle) { | 205 void BrowserChildProcessHostImpl::SetHandle(base::ProcessHandle handle) { |
| 201 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); | 206 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
| 202 data_.handle = handle; | 207 data_.handle = handle; |
| 203 } | 208 } |
| 204 | 209 |
| (...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 352 | 357 |
| 353 void BrowserChildProcessHostImpl::OnProcessExitedEarly( | 358 void BrowserChildProcessHostImpl::OnProcessExitedEarly( |
| 354 base::WaitableEvent* event) { | 359 base::WaitableEvent* event) { |
| 355 DeleteProcessWaitableEvent(event); | 360 DeleteProcessWaitableEvent(event); |
| 356 OnChildDisconnected(); | 361 OnChildDisconnected(); |
| 357 } | 362 } |
| 358 | 363 |
| 359 #endif | 364 #endif |
| 360 | 365 |
| 361 } // namespace content | 366 } // namespace content |
| OLD | NEW |