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

Unified Diff: content/renderer/media/webrtc/peer_connection_dependency_factory.cc

Issue 545203002: Improved native WebRTC logging for failing initialization of MS source (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Feedback from xians@ Created 6 years, 3 months 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/media/webrtc/peer_connection_dependency_factory.cc
diff --git a/content/renderer/media/webrtc/peer_connection_dependency_factory.cc b/content/renderer/media/webrtc/peer_connection_dependency_factory.cc
index dc072860d128ec361375b812db72fea2cde23532..6c04bde64b89796d17391a720fb0ef72bc502ee7 100644
--- a/content/renderer/media/webrtc/peer_connection_dependency_factory.cc
+++ b/content/renderer/media/webrtc/peer_connection_dependency_factory.cc
@@ -7,6 +7,7 @@
#include <vector>
#include "base/command_line.h"
+#include "base/strings/stringprintf.h"
#include "base/strings/utf_string_conversions.h"
#include "base/synchronization/waitable_event.h"
#include "content/common/media/media_stream_messages.h"
@@ -27,6 +28,7 @@
#include "content/renderer/media/webrtc/webrtc_video_capturer_adapter.h"
#include "content/renderer/media/webrtc_audio_device_impl.h"
#include "content/renderer/media/webrtc_local_audio_track.h"
+#include "content/renderer/media/webrtc_logging.h"
#include "content/renderer/media/webrtc_uma_histograms.h"
#include "content/renderer/p2p/ipc_network_manager.h"
#include "content/renderer/p2p/ipc_socket_factory.h"
@@ -216,8 +218,10 @@ bool PeerConnectionDependencyFactory::InitializeMediaStreamAudioSource(
CreateAudioCapturer(render_view_id, device_info, audio_constraints,
source_data));
if (!capturer.get()) {
- DLOG(WARNING) << "Failed to create the capturer for device "
- << device_info.device.id;
+ const std::string log_string = base::StringPrintf(
tommi (sloooow) - chröme 2014/09/05 13:09:06 doesn't look like you need StringPrintf here, righ
henrika (OOO until Aug 14) 2014/09/05 13:11:33 I am sooooo stupid. Thanks.
+ "PCDF::InitializeMediaStreamAudioSource: fails to create capturer");
+ WebRtcLogMessage(log_string);
+ DVLOG(1) << log_string;
// TODO(xians): Don't we need to check if source_observer is observing
// something? If not, then it looks like we have a leak here.
// OTOH, if it _is_ observing something, then the callback might
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698