OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 "build/build_config.h" | 5 #include "build/build_config.h" |
6 | 6 |
7 #include "chrome/browser/nacl_host/nacl_process_host.h" | 7 #include "chrome/browser/nacl_host/nacl_process_host.h" |
8 | 8 |
9 #if defined(OS_POSIX) | 9 #if defined(OS_POSIX) |
10 #include <fcntl.h> | 10 #include <fcntl.h> |
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
153 #endif | 153 #endif |
154 | 154 |
155 return true; | 155 return true; |
156 } | 156 } |
157 | 157 |
158 void NaClProcessHost::OnProcessLaunchedByBroker(base::ProcessHandle handle) { | 158 void NaClProcessHost::OnProcessLaunchedByBroker(base::ProcessHandle handle) { |
159 set_handle(handle); | 159 set_handle(handle); |
160 OnProcessLaunched(); | 160 OnProcessLaunched(); |
161 } | 161 } |
162 | 162 |
163 bool NaClProcessHost::DidChildCrash() { | 163 base::TerminationStatus NaClProcessHost::GetChildTerminationStatus( |
| 164 int* exit_code) { |
164 if (running_on_wow64_) | 165 if (running_on_wow64_) |
165 return base::DidProcessCrash(NULL, handle()); | 166 return base::GetTerminationStatus(handle(), exit_code); |
166 return BrowserChildProcessHost::DidChildCrash(); | 167 return BrowserChildProcessHost::GetChildTerminationStatus(exit_code); |
167 } | 168 } |
168 | 169 |
169 void NaClProcessHost::OnChildDied() { | 170 void NaClProcessHost::OnChildDied() { |
170 #if defined(OS_WIN) | 171 #if defined(OS_WIN) |
171 NaClBrokerService::GetInstance()->OnLoaderDied(); | 172 NaClBrokerService::GetInstance()->OnLoaderDied(); |
172 #endif | 173 #endif |
173 BrowserChildProcessHost::OnChildDied(); | 174 BrowserChildProcessHost::OnChildDied(); |
174 } | 175 } |
175 | 176 |
176 void NaClProcessHost::OnProcessLaunched() { | 177 void NaClProcessHost::OnProcessLaunched() { |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
277 if (fnIsWow64Process != NULL) { | 278 if (fnIsWow64Process != NULL) { |
278 BOOL bIsWow64 = FALSE; | 279 BOOL bIsWow64 = FALSE; |
279 if (fnIsWow64Process(GetCurrentProcess(),&bIsWow64)) { | 280 if (fnIsWow64Process(GetCurrentProcess(),&bIsWow64)) { |
280 if (bIsWow64) { | 281 if (bIsWow64) { |
281 running_on_wow64_ = true; | 282 running_on_wow64_ = true; |
282 } | 283 } |
283 } | 284 } |
284 } | 285 } |
285 } | 286 } |
286 #endif | 287 #endif |
OLD | NEW |