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

Side by Side Diff: crash_reporter.cc

Issue 3380022: Fix build break. (Closed) Base URL: http://git.chromium.org/git/crash-reporter.git
Patch Set: Created 10 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 | Annotate | Revision Log
« 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) 2010 The Chromium OS Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium OS 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 <string> 5 #include <string>
6 6
7 #include "base/file_util.h" 7 #include "base/file_util.h"
8 #include "base/command_line.h"
8 #include "base/logging.h" 9 #include "base/logging.h"
9 #include "base/string_util.h" 10 #include "base/string_util.h"
10 #include "crash-reporter/kernel_collector.h" 11 #include "crash-reporter/kernel_collector.h"
11 #include "crash-reporter/system_logging.h" 12 #include "crash-reporter/system_logging.h"
12 #include "crash-reporter/unclean_shutdown_collector.h" 13 #include "crash-reporter/unclean_shutdown_collector.h"
13 #include "crash-reporter/user_collector.h" 14 #include "crash-reporter/user_collector.h"
14 #include "gflags/gflags.h" 15 #include "gflags/gflags.h"
15 #include "metrics/metrics_library.h" 16 #include "metrics/metrics_library.h"
16 17
17 #pragma GCC diagnostic ignored "-Wstrict-aliasing" 18 #pragma GCC diagnostic ignored "-Wstrict-aliasing"
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 } 137 }
137 return 0; 138 return 0;
138 } 139 }
139 140
140 141
141 int main(int argc, char *argv[]) { 142 int main(int argc, char *argv[]) {
142 google::ParseCommandLineFlags(&argc, &argv, true); 143 google::ParseCommandLineFlags(&argc, &argv, true);
143 FilePath my_path(argv[0]); 144 FilePath my_path(argv[0]);
144 file_util::AbsolutePath(&my_path); 145 file_util::AbsolutePath(&my_path);
145 s_metrics_lib.Init(); 146 s_metrics_lib.Init();
146 InitLogging(NULL, 147 CommandLine::Init(argc,argv);
Chris Masone 2010/09/21 23:56:15 nit: space after the comma
147 LOG_ONLY_TO_SYSTEM_DEBUG_LOG, 148 logging::InitLogging(NULL,
148 DONT_LOCK_LOG_FILE, 149 logging::LOG_ONLY_TO_SYSTEM_DEBUG_LOG,
149 DELETE_OLD_LOG_FILE); 150 logging::DONT_LOCK_LOG_FILE,
151 logging::DELETE_OLD_LOG_FILE);
150 s_system_log.Initialize(my_path.BaseName().value().c_str()); 152 s_system_log.Initialize(my_path.BaseName().value().c_str());
151 KernelCollector kernel_collector; 153 KernelCollector kernel_collector;
152 kernel_collector.Initialize(CountKernelCrash, 154 kernel_collector.Initialize(CountKernelCrash,
153 IsFeedbackAllowed, 155 IsFeedbackAllowed,
154 &s_system_log); 156 &s_system_log);
155 UserCollector user_collector; 157 UserCollector user_collector;
156 user_collector.Initialize(CountUserCrash, 158 user_collector.Initialize(CountUserCrash,
157 my_path.value(), 159 my_path.value(),
158 IsFeedbackAllowed, 160 IsFeedbackAllowed,
159 &s_system_log, 161 &s_system_log,
(...skipping 10 matching lines...) Expand all
170 } 172 }
171 173
172 if (FLAGS_clean_shutdown) { 174 if (FLAGS_clean_shutdown) {
173 unclean_shutdown_collector.Disable(); 175 unclean_shutdown_collector.Disable();
174 user_collector.Disable(); 176 user_collector.Disable();
175 return 0; 177 return 0;
176 } 178 }
177 179
178 return HandleUserCrash(&user_collector); 180 return HandleUserCrash(&user_collector);
179 } 181 }
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