[vlc-devel] [PATCH 2/6] chromecast: add some debug logs
Steve Lhomme
robux4 at videolabs.io
Wed Oct 7 15:36:38 CEST 2015
---
modules/stream_out/chromecast/cast.cpp | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/modules/stream_out/chromecast/cast.cpp b/modules/stream_out/chromecast/cast.cpp
index 3ce9024..dfab8b3 100644
--- a/modules/stream_out/chromecast/cast.cpp
+++ b/modules/stream_out/chromecast/cast.cpp
@@ -431,6 +431,10 @@ static int sendMessage(sout_stream_t *p_stream, castchannel::CastMessage &msg)
if (p_data == NULL)
return -1;
+#ifndef NDEBUG
+ msg_Dbg(p_stream, "sendMessage: %s payload:%s", msg.namespace_().c_str(), msg.payload_utf8().c_str());
+#endif
+
memcpy(p_data, &i_sizeNetwork, PACKET_HEADER_LEN);
msg.SerializeWithCachedSizesToArray((uint8_t *)(p_data + PACKET_HEADER_LEN));
@@ -593,6 +597,10 @@ static int processMessage(sout_stream_t *p_stream, const castchannel::CastMessag
sout_stream_sys_t *p_sys = p_stream->p_sys;
std::string namespace_ = msg.namespace_();
+#ifndef NDEBUG
+ msg_Dbg(p_stream,"processMessage: %s payload:%s", namespace_.c_str(), msg.payload_utf8().c_str());
+#endif
+
if (namespace_ == "urn:x-cast:com.google.cast.tp.deviceauth")
{
castchannel::DeviceAuthMessage authMessage;
--
2.5.2
More information about the vlc-devel
mailing list