diff options
author | Glenn Kasten <gkasten@google.com> | 2012-01-30 14:54:39 -0800 |
---|---|---|
committer | Glenn Kasten <gkasten@google.com> | 2012-02-03 14:42:43 -0800 |
commit | c19e22450e6e3d07594c935c7a9522e85e909e82 (patch) | |
tree | 2a81eb366d10425b83b6bbf9997d9c8813515ea1 /services/audioflinger/AudioFlinger.h | |
parent | 787bae0578fbaab6219ebf23494866b224d01438 (diff) | |
download | frameworks_av-c19e22450e6e3d07594c935c7a9522e85e909e82.zip frameworks_av-c19e22450e6e3d07594c935c7a9522e85e909e82.tar.gz frameworks_av-c19e22450e6e3d07594c935c7a9522e85e909e82.tar.bz2 |
Use virtual destructors
It turns out to be just a comment, as all except AudioMixer are RefBase.
There are only a few performance-sensitive cases where it's worth thinking
about whether you need a virtual destructor, and the headache usually
outweighs the benefit.
Change-Id: I716292f9556ec17c29ce8c76ac8ae602cb496533
Diffstat (limited to 'services/audioflinger/AudioFlinger.h')
-rw-r--r-- | services/audioflinger/AudioFlinger.h | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/services/audioflinger/AudioFlinger.h b/services/audioflinger/AudioFlinger.h index 3f3188c..1a1a686 100644 --- a/services/audioflinger/AudioFlinger.h +++ b/services/audioflinger/AudioFlinger.h @@ -322,7 +322,7 @@ private: uint32_t flags, const sp<IMemory>& sharedBuffer, int sessionId); - ~TrackBase(); + virtual ~TrackBase(); virtual status_t start() = 0; virtual void stop() = 0; @@ -581,7 +581,7 @@ private: int frameCount, const sp<IMemory>& sharedBuffer, int sessionId); - ~Track(); + virtual ~Track(); void dump(char* buffer, size_t size); virtual status_t start(); @@ -664,7 +664,7 @@ private: audio_format_t format, uint32_t channelMask, int frameCount); - ~OutputTrack(); + virtual ~OutputTrack(); virtual status_t start(); virtual void stop(); @@ -845,7 +845,7 @@ private: public: DirectOutputThread (const sp<AudioFlinger>& audioFlinger, AudioStreamOut* output, int id, uint32_t device); - ~DirectOutputThread(); + virtual ~DirectOutputThread(); // Thread virtuals virtual bool threadLoop(); @@ -871,7 +871,7 @@ private: class DuplicatingThread : public MixerThread { public: DuplicatingThread (const sp<AudioFlinger>& audioFlinger, MixerThread* mainThread, int id); - ~DuplicatingThread(); + virtual ~DuplicatingThread(); // Thread virtuals virtual bool threadLoop(); @@ -946,7 +946,7 @@ private: int frameCount, uint32_t flags, int sessionId); - ~RecordTrack(); + virtual ~RecordTrack(); virtual status_t start(); virtual void stop(); @@ -975,7 +975,7 @@ private: uint32_t channels, int id, uint32_t device); - ~RecordThread(); + virtual ~RecordThread(); virtual bool threadLoop(); virtual status_t readyToRun(); @@ -1064,7 +1064,7 @@ private: effect_descriptor_t *desc, int id, int sessionId); - ~EffectModule(); + virtual ~EffectModule(); enum effect_state { IDLE, @@ -1241,7 +1241,7 @@ mutable Mutex mLock; // mutex for process, commands and handl class EffectChain: public RefBase { public: EffectChain(const wp<ThreadBase>& wThread, int sessionId); - ~EffectChain(); + virtual ~EffectChain(); // special key used for an entry in mSuspendedEffects keyed vector // corresponding to a suspend all request. |