Thank you for your report.   We have a similar report here:
     https://groups.google.com/forum/#!topic/android-ndk/G7dLKAGGL28
I think I might have a fix, but I am looking for a test case.
Do you have a test case you can share, that is simpler than Skype?

On Tuesday, May 13, 2014 9:58:34 PM UTC-7, Katy Ma wrote:
>
> When using skype call, sometimes skype call cannot be end if press end 
> call button, and such log will appear,
>
> "W/libOpenSLES( 2355): 
> frameworks/wilhelm/src/android/AudioRecorder_to_android.cpp:217: pthread 
> 0x62471b80 (tid 2810) sees object 0x66a0d518 was locked by pthread 
> 0x5fb4cc90 (tid 2377) at frameworks/wilhelm/src/itf/IObject.c:411"
>
> I think when end skype call, 
>
> 1. libOpenSLES to destroy CAudioRecorder(object locked, later will unlock 
> only in IObject_deinit after finish destroyed in 3.)
> 2. EVENT_MORE_DATA/EVENT_OVERRUN(etc.) happens and skype callback function 
> will handle the event with a lock(requires lock in 1.).
> 3. After  1.,  ~AudioRecord  will  be  called  during  destroy,it will wait 
> for a lock only when mThreadExitedCondition.broadcast() after 
> AudioRecordThread returns, however AudioRecordThread is blocked in 
> processAudioBuffer when handle EVENT_MORE_DATA/EVENT_OVERRUN(etc.)(requires 
> lock in 2.) However 1. cannot be finished if 3. is blocked. 
>
>
> So dead lock happened.
>
>
> It seems that when destroy CAudioRecoder, there's no need to handle the 
> event, however it's hard to sync. And handling event with lock may cause 
> deadlock when destroy CAudioRecorder.
>
>
> So can we just remove the lock when handling event? Why we need lock here? 
>
>
>

-- 
-- 
unsubscribe: android-porting+unsubscr...@googlegroups.com
website: http://groups.google.com/group/android-porting

--- 
You received this message because you are subscribed to the Google Groups 
"android-porting" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-porting+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to