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

Commit 82e5ab31 authored by Chih-Yu Huang's avatar Chih-Yu Huang Committed by Chih-yu Huang
Browse files

CCodec: log the component name when the codec is stuck

The video and audio components usually runs at the same time. It's
hard to know which component is stuck if we don't print the name. This
CL adds the component name at the warning log when the codec is stuck.

Bug: 174188958
Test: m -j32
Change-Id: Iaaea1b79ee85efb1346983af6ea91415ced299c4
(cherry picked from commit 183323963f26c362d04d49b2896ca3296bf6abf8)
parent ef8f74b2
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -2311,7 +2311,13 @@ void CCodec::initiateReleaseIfStuck() {
        return;
    }

    ALOGW("previous call to %s exceeded timeout", name.c_str());
    C2String compName;
    {
        Mutexed<State>::Locked state(mState);
        compName = state->comp->getName();
    }
    ALOGW("[%s] previous call to %s exceeded timeout", compName.c_str(), name.c_str());

    initiateRelease(false);
    mCallback->onError(UNKNOWN_ERROR, ACTION_CODE_FATAL);
}