Block all internal logs when running without `--enable-logging`

This commit is contained in:
Eran Tiktin 2015-10-10 20:44:22 +03:00
Родитель 4e8db2c3be
Коммит cb903a09c0
1 изменённых файлов: 3 добавлений и 1 удалений

Просмотреть файл

@ -48,8 +48,10 @@ bool AtomMainDelegate::BasicStartupComplete(int* exit_code) {
// Only enable logging when --enable-logging is specified.
auto command_line = base::CommandLine::ForCurrentProcess();
if (!command_line->HasSwitch(switches::kEnableLogging))
if (!command_line->HasSwitch(switches::kEnableLogging)) {
settings.logging_dest = logging::LOG_NONE;
logging::SetMinLogLevel(logging::LOG_NUM_SEVERITIES);
}
logging::InitLogging(settings);