Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7a69aeff authored by repo sync's avatar repo sync
Browse files

RTP: Add log throttle for "no data".

Change-Id: I14d9886a40fa780514cbc6c5bac6fb2a670f55f4
parent 4033a67d
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -104,6 +104,7 @@ private:
    int mSampleRate;
    int mSampleCount;
    int mInterval;
    int mLogThrottle;

    int16_t *mBuffer;
    int mBufferMask;
@@ -278,7 +279,10 @@ void AudioStream::encode(int tick, AudioStream *chain)
        chain = chain->mNext;
    }
    if (!mixed) {
        if ((mTick ^ mLogThrottle) >> 10) {
            mLogThrottle = mTick;
            LOGD("stream[%d] no data", mSocket);
        }
        return;
    }