819ab3a683b0a94471fcb32b4cf9977d8a5086e8 |
|
12-Sep-2011 |
Glenn Kasten <gkasten@google.com> |
Bug 5090073 Callback protectors Add callback protector for decode to PCM usage cases. Move callback protection up earlier for URI decode use case only. Other: Remove redundant mCallbackProtector field. Optimization: on exit from callback protector, only broadcast if !mSafeToEnterCb, that is if destroy has requested callback protectors to finish up. More callback protector logging. Add callback protector requestCbExit() [no wait], not yet used. Unrelated: 3rd parameter of adecoder_writeToBufferQueue is always CAudioPlayer * instead of void *. Change-Id: I57a46acf0e5ecb213540b13ca08098177ad7ad6e
/system/media/wilhelm/src/android/CallbackProtector.h
|
abf6db3696e93960f7bc943e8235ba31f73e5c3f |
|
24-Aug-2011 |
Glenn Kasten <gkasten@google.com> |
Bug 5193695 Fix crash after MediaPlayer destroyed The StreamSource callback thread was continuing to run after the MediaPlayer object was destroyed. Fixed by adding a callback protector and a pre-destroy hook. GenericMediaPlayer::preDestroy now also calls MediaPlayer::stop just in case. Change-Id: I5bd771d4d1936f433d2a8c9959593782c96daed9 Miscellaneous: - added an explicit destructor on CMediaPlayer::mAVPlayer for consistency (probably not a bug since there was a clear on it earlier) - updated comments for CallbackProtector - made some CallbackProtector fields private since no sub-classes yet
/system/media/wilhelm/src/android/CallbackProtector.h
|
272648a4efd07fc308ec1622b3951537c2f2c63a |
|
28-Jun-2011 |
Jean-Michel Trivi <jmtrivi@google.com> |
Fix race condition when deleting an AudioPlayer When deleting an AudioPlayer that is used as a PCM decoder, there can be callback underway, for instance when trying to delete a player just as the notification of its preparation arrives. The fix consists in: - flagging all callback with the CallbackProtector mechanism, - only entering callback when it is valid to do so - renaming AudioTrackProtector to CallbackProtector as this mechanism is not exclusively used for the AudioTrack callbacks. Change-Id: I9336a75981de43f71a983c1300f3a0ff314ac1e0
/system/media/wilhelm/src/android/CallbackProtector.h
|