1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-12-15 09:01:12 +01:00

Manage block files with std::shared_ptr, BlockHash stores weak_ptr

This commit is contained in:
Paul Licameli
2016-08-16 10:52:43 -04:00
parent 84ccdca5c3
commit 8b72bd2f92
14 changed files with 51 additions and 230 deletions

View File

@@ -143,13 +143,6 @@ protected:
sampleFormat format, ArrayOf<char> &cleanup) override;
private:
//Thread-safe versions
void Ref() const override;
bool Deref() const override;
//needed for Ref/Deref access.
friend class DirManager;
friend class ODComputeSummaryTask;
friend class ODDecodeTask;
ODLock mWriteSummaryMutex;
@@ -162,11 +155,6 @@ protected:
//lock the read data - libsndfile can't handle two reads at once?
mutable ODLock mReadDataMutex;
//lock the Ref counting
mutable ODLock mDerefMutex;
mutable ODLock mRefMutex;
mutable ODLock mSummaryAvailableMutex;
bool mSummaryAvailable;
bool mSummaryBeingComputed;