Loading media/libaaudio/src/core/AudioStream.cpp +4 −0 Original line number Diff line number Diff line Loading @@ -480,6 +480,10 @@ void* AudioStream::wrapUserThread() { // Run callback loop. This may take a very long time. procResult = mThreadProc(mThreadArg); mThreadRegistrationResult = unregisterThread(); } else { // If we cannot register the thread then it has probably become disconnected. // The only way to inform the app from this thread is with an error callback. maybeCallErrorCallback(AAUDIO_ERROR_DISCONNECTED); } return procResult; } Loading services/audioflinger/Threads.cpp +3 −0 Original line number Diff line number Diff line Loading @@ -10423,8 +10423,11 @@ void MmapThread::disconnect() activeTracks.add(t); } localPortId = mPortId; ALOGD("%s: localPortId = %d", __func__, localPortId); mPortId = AUDIO_PORT_HANDLE_NONE; } for (const sp<IAfMmapTrack>& t : activeTracks) { ALOGD("%s: t->portId() = %d", __func__, t->portId()); stop(t->portId()); } // This will decrement references and may cause the destruction of this thread. Loading Loading
media/libaaudio/src/core/AudioStream.cpp +4 −0 Original line number Diff line number Diff line Loading @@ -480,6 +480,10 @@ void* AudioStream::wrapUserThread() { // Run callback loop. This may take a very long time. procResult = mThreadProc(mThreadArg); mThreadRegistrationResult = unregisterThread(); } else { // If we cannot register the thread then it has probably become disconnected. // The only way to inform the app from this thread is with an error callback. maybeCallErrorCallback(AAUDIO_ERROR_DISCONNECTED); } return procResult; } Loading
services/audioflinger/Threads.cpp +3 −0 Original line number Diff line number Diff line Loading @@ -10423,8 +10423,11 @@ void MmapThread::disconnect() activeTracks.add(t); } localPortId = mPortId; ALOGD("%s: localPortId = %d", __func__, localPortId); mPortId = AUDIO_PORT_HANDLE_NONE; } for (const sp<IAfMmapTrack>& t : activeTracks) { ALOGD("%s: t->portId() = %d", __func__, t->portId()); stop(t->portId()); } // This will decrement references and may cause the destruction of this thread. Loading