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

Side by Side Diff: net/tools/tld_cleanup/tld_cleanup.cc

Issue 8467028: Enable DVLOG on non official release build based on the parameter passed for InitLogging. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: For review. Created 9 years, 1 month 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 | « net/tools/testserver/run_testserver.cc ('k') | webkit/support/webkit_support.cc » ('j') | 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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 // This command-line program converts an effective-TLD data file in UTF-8 from 5 // This command-line program converts an effective-TLD data file in UTF-8 from
6 // the format provided by Mozilla to the format expected by Chrome. This 6 // the format provided by Mozilla to the format expected by Chrome. This
7 // program generates an intermediate file which is then used by gperf to 7 // program generates an intermediate file which is then used by gperf to
8 // generate a perfect hash map. The benefit of this approach is that no time is 8 // generate a perfect hash map. The benefit of this approach is that no time is
9 // spent on program initialization to generate the map of this data. 9 // spent on program initialization to generate the map of this data.
10 // 10 //
(...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after
264 CommandLine::Init(argc, argv); 264 CommandLine::Init(argc, argv);
265 265
266 FilePath log_filename; 266 FilePath log_filename;
267 PathService::Get(base::DIR_EXE, &log_filename); 267 PathService::Get(base::DIR_EXE, &log_filename);
268 log_filename = log_filename.AppendASCII("tld_cleanup.log"); 268 log_filename = log_filename.AppendASCII("tld_cleanup.log");
269 logging::InitLogging( 269 logging::InitLogging(
270 log_filename.value().c_str(), 270 log_filename.value().c_str(),
271 destination, 271 destination,
272 logging::LOCK_LOG_FILE, 272 logging::LOCK_LOG_FILE,
273 logging::DELETE_OLD_LOG_FILE, 273 logging::DELETE_OLD_LOG_FILE,
274 logging::DISABLE_DCHECK_FOR_NON_OFFICIAL_RELEASE_BUILDS); 274 logging::DISABLE_DCHECK_FOR_NON_OFFICIAL_RELEASE_BUILDS,
275 logging::DISABLE_DLOG_FOR_NON_OFFICIAL_RELEASE_BUILDS);
275 276
276 icu_util::Initialize(); 277 icu_util::Initialize();
277 278
278 FilePath input_file; 279 FilePath input_file;
279 PathService::Get(base::DIR_SOURCE_ROOT, &input_file); 280 PathService::Get(base::DIR_SOURCE_ROOT, &input_file);
280 input_file = input_file.Append(FILE_PATH_LITERAL("net")) 281 input_file = input_file.Append(FILE_PATH_LITERAL("net"))
281 .Append(FILE_PATH_LITERAL("base")) 282 .Append(FILE_PATH_LITERAL("base"))
282 .Append(FILE_PATH_LITERAL("effective_tld_names.dat")); 283 .Append(FILE_PATH_LITERAL("effective_tld_names.dat"));
283 FilePath output_file; 284 FilePath output_file;
284 PathService::Get(base::DIR_SOURCE_ROOT, &output_file); 285 PathService::Get(base::DIR_SOURCE_ROOT, &output_file);
285 output_file = output_file.Append(FILE_PATH_LITERAL("net")) 286 output_file = output_file.Append(FILE_PATH_LITERAL("net"))
286 .Append(FILE_PATH_LITERAL("base")) 287 .Append(FILE_PATH_LITERAL("base"))
287 .Append(FILE_PATH_LITERAL( 288 .Append(FILE_PATH_LITERAL(
288 "effective_tld_names.gperf")); 289 "effective_tld_names.gperf"));
289 NormalizeResult result = NormalizeFile(input_file, output_file); 290 NormalizeResult result = NormalizeFile(input_file, output_file);
290 if (result != kSuccess) { 291 if (result != kSuccess) {
291 fprintf(stderr, 292 fprintf(stderr,
292 "Errors or warnings processing file. See log in tld_cleanup.log."); 293 "Errors or warnings processing file. See log in tld_cleanup.log.");
293 } 294 }
294 295
295 if (result == kError) 296 if (result == kError)
296 return 1; 297 return 1;
297 return 0; 298 return 0;
298 } 299 }
OLDNEW
« no previous file with comments | « net/tools/testserver/run_testserver.cc ('k') | webkit/support/webkit_support.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698