diff options
author | gspencer@chromium.org <gspencer@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-10-28 00:20:21 +0000 |
---|---|---|
committer | gspencer@chromium.org <gspencer@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-10-28 00:20:21 +0000 |
commit | c7d5da999d7320eff6826e4c18fce3f4a083b575 (patch) | |
tree | f41be2c85bfac03a86f6fd03da92720070c23d89 /base/logging.cc | |
parent | e913806556b5a09fe012a60d0be91b4ddea2443c (diff) | |
download | chromium_src-c7d5da999d7320eff6826e4c18fce3f4a083b575.zip chromium_src-c7d5da999d7320eff6826e4c18fce3f4a083b575.tar.gz chromium_src-c7d5da999d7320eff6826e4c18fce3f4a083b575.tar.bz2 |
This fixes the logging for ChromeOS so that it uses symlinks
to log to instead of going to the timestamped files directly, so that
the browser process can more precisely control the output file being
used. It still creates timestamped logs, and the regular chrome
operations should be unchanged.
Added a bool return value to InitLogging so we know when it fails,
because failing needs to be handled properly in ChromeOS to remove
hanging symbolic links.
[This change has already been reviewed and approved here:
http://codereview.chromium.org/3983004/show
Somehow the dcommit failed without me noticing, so I'm trying
again.]
BUG=http://crosbug.com/6343
TEST=ran on device in incognito and regular mode, looked at logs.
Review URL: http://codereview.chromium.org/4167004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@64184 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/logging.cc')
-rw-r--r-- | base/logging.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/base/logging.cc b/base/logging.cc index a6b52a7..e78b1a4 100644 --- a/base/logging.cc +++ b/base/logging.cc @@ -336,7 +336,7 @@ bool InitializeLogFileHandle() { return true; } -void BaseInitLoggingImpl(const PathChar* new_log_file, +bool BaseInitLoggingImpl(const PathChar* new_log_file, LoggingDestination logging_dest, LogLockingState lock_log, OldFileDeletionState delete_old) { @@ -370,7 +370,7 @@ void BaseInitLoggingImpl(const PathChar* new_log_file, // ignore file options if logging is disabled or only to system if (logging_destination == LOG_NONE || logging_destination == LOG_ONLY_TO_SYSTEM_DEBUG_LOG) - return; + return true; if (!log_file_name) log_file_name = new PathString(); @@ -378,7 +378,7 @@ void BaseInitLoggingImpl(const PathChar* new_log_file, if (delete_old == DELETE_OLD_LOG_FILE) DeleteFilePath(*log_file_name); - InitializeLogFileHandle(); + return InitializeLogFileHandle(); } void SetMinLogLevel(int level) { |