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

Commit cd7c3e26 authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Fix CodecLooper queue block issue" into main am: 1f4ed7f4

parents 174a191a 1f4ed7f4
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -2326,10 +2326,13 @@ status_t CCodec::unsubscribeFromParameters(const std::vector<std::string> &names
void CCodec::onWorkDone(std::list<std::unique_ptr<C2Work>> &workItems) {
    if (!workItems.empty()) {
        Mutexed<std::list<std::unique_ptr<C2Work>>>::Locked queue(mWorkDoneQueue);
        bool shouldPost = queue->empty();
        queue->splice(queue->end(), workItems);
    }
        if (shouldPost) {
            (new AMessage(kWhatWorkDone, this))->post();
        }
    }
}

void CCodec::onInputBufferDone(uint64_t frameIndex, size_t arrayIndex) {
    mChannel->onInputBufferDone(frameIndex, arrayIndex);