Loading services/audioflinger/AudioFlinger.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -2094,7 +2094,7 @@ sp<AudioFlinger::SyncEvent> AudioFlinger::createSyncEvent(AudioSystem::sync_even int triggerSession, int listenerSession, sync_event_callback_t callBack, void *cookie) wp<RefBase> cookie) { Mutex::Autolock _l(mLock); Loading services/audioflinger/AudioFlinger.h +4 −4 Original line number Diff line number Diff line Loading @@ -253,7 +253,7 @@ public: int triggerSession, int listenerSession, sync_event_callback_t callBack, void *cookie) wp<RefBase> cookie) : mType(type), mTriggerSession(triggerSession), mListenerSession(listenerSession), mCallback(callBack), mCookie(cookie) {} Loading @@ -266,14 +266,14 @@ public: AudioSystem::sync_event_t type() const { return mType; } int triggerSession() const { return mTriggerSession; } int listenerSession() const { return mListenerSession; } void *cookie() const { return mCookie; } wp<RefBase> cookie() const { return mCookie; } private: const AudioSystem::sync_event_t mType; const int mTriggerSession; const int mListenerSession; sync_event_callback_t mCallback; void * const mCookie; const wp<RefBase> mCookie; mutable Mutex mLock; }; Loading @@ -281,7 +281,7 @@ public: int triggerSession, int listenerSession, sync_event_callback_t callBack, void *cookie); wp<RefBase> cookie); private: class AudioHwDevice; // fwd declaration for findSuitableHwDev_l Loading services/audioflinger/Threads.cpp +5 −2 Original line number Diff line number Diff line Loading @@ -5095,10 +5095,13 @@ void AudioFlinger::RecordThread::syncStartEventCallback(const wp<SyncEvent>& eve sp<SyncEvent> strongEvent = event.promote(); if (strongEvent != 0) { RecordTrack *recordTrack = (RecordTrack *)strongEvent->cookie(); sp<RefBase> ptr = strongEvent->cookie().promote(); if (ptr != 0) { RecordTrack *recordTrack = (RecordTrack *)ptr.get(); recordTrack->handleSyncStartEvent(strongEvent); } } } bool AudioFlinger::RecordThread::stop(RecordThread::RecordTrack* recordTrack) { ALOGV("RecordThread::stop"); Loading Loading
services/audioflinger/AudioFlinger.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -2094,7 +2094,7 @@ sp<AudioFlinger::SyncEvent> AudioFlinger::createSyncEvent(AudioSystem::sync_even int triggerSession, int listenerSession, sync_event_callback_t callBack, void *cookie) wp<RefBase> cookie) { Mutex::Autolock _l(mLock); Loading
services/audioflinger/AudioFlinger.h +4 −4 Original line number Diff line number Diff line Loading @@ -253,7 +253,7 @@ public: int triggerSession, int listenerSession, sync_event_callback_t callBack, void *cookie) wp<RefBase> cookie) : mType(type), mTriggerSession(triggerSession), mListenerSession(listenerSession), mCallback(callBack), mCookie(cookie) {} Loading @@ -266,14 +266,14 @@ public: AudioSystem::sync_event_t type() const { return mType; } int triggerSession() const { return mTriggerSession; } int listenerSession() const { return mListenerSession; } void *cookie() const { return mCookie; } wp<RefBase> cookie() const { return mCookie; } private: const AudioSystem::sync_event_t mType; const int mTriggerSession; const int mListenerSession; sync_event_callback_t mCallback; void * const mCookie; const wp<RefBase> mCookie; mutable Mutex mLock; }; Loading @@ -281,7 +281,7 @@ public: int triggerSession, int listenerSession, sync_event_callback_t callBack, void *cookie); wp<RefBase> cookie); private: class AudioHwDevice; // fwd declaration for findSuitableHwDev_l Loading
services/audioflinger/Threads.cpp +5 −2 Original line number Diff line number Diff line Loading @@ -5095,10 +5095,13 @@ void AudioFlinger::RecordThread::syncStartEventCallback(const wp<SyncEvent>& eve sp<SyncEvent> strongEvent = event.promote(); if (strongEvent != 0) { RecordTrack *recordTrack = (RecordTrack *)strongEvent->cookie(); sp<RefBase> ptr = strongEvent->cookie().promote(); if (ptr != 0) { RecordTrack *recordTrack = (RecordTrack *)ptr.get(); recordTrack->handleSyncStartEvent(strongEvent); } } } bool AudioFlinger::RecordThread::stop(RecordThread::RecordTrack* recordTrack) { ALOGV("RecordThread::stop"); Loading