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

Commit 9ffb82eb authored by Hangyu Kuang's avatar Hangyu Kuang Committed by Android (Google) Code Review
Browse files

Merge "stagefright: stop audio encoding before releasing writer thread"

parents cd201da8 9e6b038e
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -154,11 +154,11 @@ status_t AACWriter::reset() {
    mDone = true;

    void *dummy;
    status_t status = mSource->stop();
    pthread_join(mThread, &dummy);

    status_t err = static_cast<status_t>(reinterpret_cast<uintptr_t>(dummy));
    {
        status_t status = mSource->stop();
        if (err == OK &&
            (status != OK && status != ERROR_END_OF_STREAM)) {
            err = status;
+1 −1
Original line number Diff line number Diff line
@@ -149,11 +149,11 @@ status_t AMRWriter::reset() {
    mDone = true;

    void *dummy;
    status_t status = mSource->stop();
    pthread_join(mThread, &dummy);

    status_t err = static_cast<status_t>(reinterpret_cast<uintptr_t>(dummy));
    {
        status_t status = mSource->stop();
        if (err == OK &&
            (status != OK && status != ERROR_END_OF_STREAM)) {
            err = status;