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

Side by Side Diff: net/tools/testserver/run_testserver.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/flip_server/flip_in_mem_edsm_server.cc ('k') | net/tools/tld_cleanup/tld_cleanup.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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 <stdio.h> 5 #include <stdio.h>
6 6
7 #include "base/at_exit.h" 7 #include "base/at_exit.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/file_path.h" 9 #include "base/file_path.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 14 matching lines...) Expand all
25 25
26 // Process command line 26 // Process command line
27 CommandLine::Init(argc, argv); 27 CommandLine::Init(argc, argv);
28 CommandLine* command_line = CommandLine::ForCurrentProcess(); 28 CommandLine* command_line = CommandLine::ForCurrentProcess();
29 29
30 if (!logging::InitLogging( 30 if (!logging::InitLogging(
31 FILE_PATH_LITERAL("testserver.log"), 31 FILE_PATH_LITERAL("testserver.log"),
32 logging::LOG_TO_BOTH_FILE_AND_SYSTEM_DEBUG_LOG, 32 logging::LOG_TO_BOTH_FILE_AND_SYSTEM_DEBUG_LOG,
33 logging::LOCK_LOG_FILE, 33 logging::LOCK_LOG_FILE,
34 logging::APPEND_TO_OLD_LOG_FILE, 34 logging::APPEND_TO_OLD_LOG_FILE,
35 logging::DISABLE_DCHECK_FOR_NON_OFFICIAL_RELEASE_BUILDS)) { 35 logging::DISABLE_DCHECK_FOR_NON_OFFICIAL_RELEASE_BUILDS,
36 logging::DISABLE_DLOG_FOR_NON_OFFICIAL_RELEASE_BUILDS)) {
36 printf("Error: could not initialize logging. Exiting.\n"); 37 printf("Error: could not initialize logging. Exiting.\n");
37 return -1; 38 return -1;
38 } 39 }
39 40
40 TestTimeouts::Initialize(); 41 TestTimeouts::Initialize();
41 42
42 if (command_line->GetSwitches().empty() || command_line->HasSwitch("help")) { 43 if (command_line->GetSwitches().empty() || command_line->HasSwitch("help")) {
43 PrintUsage(); 44 PrintUsage();
44 return -1; 45 return -1;
45 } 46 }
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 UTF16ToUTF8(test_server->document_root().LossyDisplayName()).c_str()); 96 UTF16ToUTF8(test_server->document_root().LossyDisplayName()).c_str());
96 return -1; 97 return -1;
97 } 98 }
98 99
99 printf("testserver running at %s (type ctrl+c to exit)\n", 100 printf("testserver running at %s (type ctrl+c to exit)\n",
100 test_server->host_port_pair().ToString().c_str()); 101 test_server->host_port_pair().ToString().c_str());
101 102
102 message_loop.Run(); 103 message_loop.Run();
103 return 0; 104 return 0;
104 } 105 }
OLDNEW
« no previous file with comments | « net/tools/flip_server/flip_in_mem_edsm_server.cc ('k') | net/tools/tld_cleanup/tld_cleanup.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698