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

Unified Diff: third_party/libjingle/overrides/init_webrtc.cc

Issue 71353010: Fix WebRTC logging so that logs from libpeerconnection make it to the log. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Code review. Created 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/libjingle/overrides/init_webrtc.h ('k') | third_party/libjingle/overrides/initialize_module.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/libjingle/overrides/init_webrtc.cc
diff --git a/third_party/libjingle/overrides/init_webrtc.cc b/third_party/libjingle/overrides/init_webrtc.cc
index 746f8831cd10fca3713c4caf013c1d4a38678e4e..e0e05321f9785528d9e368dcedd93d9709585b3d 100644
--- a/third_party/libjingle/overrides/init_webrtc.cc
+++ b/third_party/libjingle/overrides/init_webrtc.cc
@@ -10,6 +10,7 @@
#include "base/native_library.h"
#include "base/path_service.h"
#include "talk/base/basictypes.h"
+#include "third_party/libjingle/overrides/talk/base/logging.h"
const unsigned char* GetCategoryGroupEnabled(const char* category_group) {
return TRACE_EVENT_API_GET_CATEGORY_GROUP_ENABLED(category_group);
@@ -95,13 +96,19 @@ bool InitializeWebRtcModule() {
// the alloc/dealloc functions.
// PS: This function is actually implemented in allocator_proxy.cc with the
// new/delete overrides.
- return initialize_module(*CommandLine::ForCurrentProcess(),
+ InitDiagnosticLoggingDelegateFunctionFunction init_diagnostic_logging = NULL;
+ bool init_ok = initialize_module(*CommandLine::ForCurrentProcess(),
#if !defined(OS_MACOSX) && !defined(OS_ANDROID)
&Allocate, &Dellocate,
#endif
logging::GetLogMessageHandler(),
&GetCategoryGroupEnabled, &AddTraceEvent,
- &g_create_webrtc_media_engine, &g_destroy_webrtc_media_engine);
+ &g_create_webrtc_media_engine, &g_destroy_webrtc_media_engine,
+ &init_diagnostic_logging);
+
+ if (init_ok)
+ talk_base::SetExtraLoggingInit(init_diagnostic_logging);
+ return init_ok;
}
cricket::MediaEngineInterface* CreateWebRtcMediaEngine(
« no previous file with comments | « third_party/libjingle/overrides/init_webrtc.h ('k') | third_party/libjingle/overrides/initialize_module.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698