Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 <fcntl.h> | 5 #include <fcntl.h> |
| 6 #include <sys/socket.h> | 6 #include <sys/socket.h> |
| 7 #include <sys/uio.h> | 7 #include <sys/uio.h> |
| 8 #include <unistd.h> | 8 #include <unistd.h> |
| 9 | 9 |
| 10 #include <string> | 10 #include <string> |
| (...skipping 500 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 511 } | 511 } |
| 512 | 512 |
| 513 void InitCrashReporter() { | 513 void InitCrashReporter() { |
| 514 if (!GoogleUpdateSettings::GetCollectStatsConsent()) | 514 if (!GoogleUpdateSettings::GetCollectStatsConsent()) |
| 515 return; | 515 return; |
| 516 | 516 |
| 517 // Determine the process type and take appropriate action. | 517 // Determine the process type and take appropriate action. |
| 518 const CommandLine& parsed_command_line = *CommandLine::ForCurrentProcess(); | 518 const CommandLine& parsed_command_line = *CommandLine::ForCurrentProcess(); |
| 519 const std::wstring process_type = | 519 const std::wstring process_type = |
| 520 parsed_command_line.GetSwitchValue(switches::kProcessType); | 520 parsed_command_line.GetSwitchValue(switches::kProcessType); |
| 521 if (process_type.empty()) | 521 if (process_type.empty()) { |
| 522 EnableCrashDumping(); | 522 EnableCrashDumping(); |
| 523 else if (process_type == switches::kRendererProcess) | 523 } else if (process_type == switches::kRendererProcess || |
| 524 process_type == switches::kZygoteProcess) { | |
|
Lei Zhang
2009/06/23 03:52:45
Is this ever the case? When does a zygote process
| |
| 524 EnableRendererCrashDumping(); | 525 EnableRendererCrashDumping(); |
| 526 } | |
| 525 } | 527 } |
| OLD | NEW |