diff options
author | agl@chromium.org <agl@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-04-03 02:19:49 +0000 |
---|---|---|
committer | agl@chromium.org <agl@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-04-03 02:19:49 +0000 |
commit | 8cf3f1dae79db8cfbf9dc6b75c140eabad918a6e (patch) | |
tree | 89e93505cc275c0a22b5ca7d95c5f03cfacff6a1 /chrome/common/logging_chrome.cc | |
parent | 343b7211ff31670cded0f85fa8a056fa6cf7a9f3 (diff) | |
download | chromium_src-8cf3f1dae79db8cfbf9dc6b75c140eabad918a6e.zip chromium_src-8cf3f1dae79db8cfbf9dc6b75c140eabad918a6e.tar.gz chromium_src-8cf3f1dae79db8cfbf9dc6b75c140eabad918a6e.tar.bz2 |
Move IPC code to ipc/
(No review URL: Rietvelt couldn't cope)
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13062 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common/logging_chrome.cc')
-rw-r--r-- | chrome/common/logging_chrome.cc | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/chrome/common/logging_chrome.cc b/chrome/common/logging_chrome.cc index 66a49cf..a68b4d6 100644 --- a/chrome/common/logging_chrome.cc +++ b/chrome/common/logging_chrome.cc @@ -25,6 +25,23 @@ #include "chrome/common/chrome_switches.h" #include "chrome/common/env_vars.h" +#if defined(OS_POSIX) +// On POSIX, this file also handles IPC logging + +#include "ipc/ipc_logging.h" +#include "ipc/ipc_message.h" + +#ifdef IPC_MESSAGE_LOG_ENABLED +// This will cause render_messages.h etc to define ViewMsgLog and friends. +#define IPC_MESSAGE_MACROS_LOG_ENABLED +// This include list should contain all _messages.h header files so that they +// can get *MsgLog function etc. This makes ipc logs much more informative. +#include "chrome/common/render_messages.h" +#include "chrome/test/automation/automation_messages.h" +#endif + +#endif + // When true, this means that error dialogs should not be shown. static bool dialogs_are_suppressed_ = false; @@ -72,6 +89,10 @@ void InitChromeLogging(const CommandLine& command_line, DCHECK(!chrome_logging_initialized_) << "Attempted to initialize logging when it was already initialized."; +#if defined(OS_POSIX) && defined(IPC_MESSAGE_LOG_ENABLED) + IPC::Logging::SetLoggerFunctions(g_log_function_mapping); +#endif + // only use OutputDebugString in debug mode #ifdef NDEBUG bool enable_logging = false; |