From 9bc8f336ae3a15d68bceff677919196686f32041 Mon Sep 17 00:00:00 2001 From: Jeremy Lainé Date: Tue, 16 Nov 2010 22:35:01 +0000 Subject: tweak RTP channel logging --- src/QXmppRtpChannel.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src') diff --git a/src/QXmppRtpChannel.cpp b/src/QXmppRtpChannel.cpp index 43e58ff8..820be1b7 100644 --- a/src/QXmppRtpChannel.cpp +++ b/src/QXmppRtpChannel.cpp @@ -88,6 +88,11 @@ QXmppRtpChannel::QXmppRtpChannel(QObject *parent) : QIODevice(parent), d(new QXmppRtpChannelPrivate) { + QXmppLoggable *logParent = qobject_cast(parent); + if (logParent) { + connect(this, SIGNAL(logMessage(QXmppLogger::MessageType,QString)), + logParent, SIGNAL(logMessage(QXmppLogger::MessageType,QString))); + } } /// Destroys an RTP channel. @@ -232,7 +237,9 @@ qint64 QXmppRtpChannel::readData(char * data, qint64 maxSize) d->incomingBuffer.remove(0, readSize); if (readSize < maxSize) { +#ifdef QXMPP_DEBUG_RTP debug(QString("QXmppRtpChannel::readData missing %1 bytes").arg(QString::number(maxSize - readSize))); +#endif memset(data + readSize, 0, maxSize - readSize); } d->incomingStamp += readSize / SAMPLE_BYTES; -- cgit v1.2.3