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

Side by Side Diff: content/gpu/gpu_main.cc

Issue 2281243002: Dead-on-arrival GPU processes should have non-zero exit code. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: change exit code to 2 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 <stddef.h> 5 #include <stddef.h>
6 #include <stdlib.h> 6 #include <stdlib.h>
7 7
8 #include <memory> 8 #include <memory>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 406 matching lines...) Expand 10 before | Expand all | Expand 10 after
417 nullptr); 417 nullptr);
418 #endif 418 #endif
419 419
420 { 420 {
421 TRACE_EVENT0("gpu", "Run Message Loop"); 421 TRACE_EVENT0("gpu", "Run Message Loop");
422 base::RunLoop().Run(); 422 base::RunLoop().Run();
423 } 423 }
424 424
425 child_thread->StopWatchdog(); 425 child_thread->StopWatchdog();
426 426
427 return 0; 427 return dead_on_arrival ? 2 : 0;
428 } 428 }
429 429
430 namespace { 430 namespace {
431 431
432 void GetGpuInfoFromCommandLine(gpu::GPUInfo& gpu_info, 432 void GetGpuInfoFromCommandLine(gpu::GPUInfo& gpu_info,
433 const base::CommandLine& command_line) { 433 const base::CommandLine& command_line) {
434 DCHECK(command_line.HasSwitch(switches::kGpuVendorID) && 434 DCHECK(command_line.HasSwitch(switches::kGpuVendorID) &&
435 command_line.HasSwitch(switches::kGpuDeviceID) && 435 command_line.HasSwitch(switches::kGpuDeviceID) &&
436 command_line.HasSwitch(switches::kGpuDriverVersion)); 436 command_line.HasSwitch(switches::kGpuDriverVersion));
437 bool success = base::HexStringToUInt( 437 bool success = base::HexStringToUInt(
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after
621 return true; 621 return true;
622 } 622 }
623 623
624 return false; 624 return false;
625 } 625 }
626 #endif // defined(OS_WIN) 626 #endif // defined(OS_WIN)
627 627
628 } // namespace. 628 } // namespace.
629 629
630 } // namespace content 630 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698