diff --git a/include/SCBufferAdaptor.hpp b/include/SCBufferAdaptor.hpp index b753a15..98195a7 100644 --- a/include/SCBufferAdaptor.hpp +++ b/include/SCBufferAdaptor.hpp @@ -87,7 +87,11 @@ public: void cleanUp() { - if (mOldData) boost::alignment::aligned_free(mOldData); + if (mOldData) + { + boost::alignment::aligned_free(mOldData); + mOldData = nullptr; + } } // No locks in (vanilla) SC, so no-ops for these @@ -147,10 +151,8 @@ public: thisThing->samplerate); } - int bufnum() - { - return mBufnum; - } + int bufnum() { return mBufnum; } + void realTime(bool rt) { mRealTime = rt; } protected: bool equal(BufferAdaptor *rhs) const override @@ -160,10 +162,11 @@ protected: return false; } - float *mOldData = 0; + bool mRealTime{false}; + float *mOldData{0}; long mBufnum; World *mWorld; - size_t mRank = 1; + size_t mRank{1}; }; class RTBufferView : public client::BufferAdaptor