--- linuxsampler/trunk/src/engines/InstrumentManagerThread.h 2006/12/06 22:28:17 970 +++ linuxsampler/trunk/src/engines/InstrumentManagerThread.h 2006/12/19 19:34:08 989 @@ -24,12 +24,11 @@ #include "../common/global.h" #include "../common/Thread.h" #include "../common/Condition.h" -#include "../common/RingBuffer.h" +#include "../common/Mutex.h" #include "../Sampler.h" #include "InstrumentManager.h" -/// Maximum numbers of instruments waiting to be loaded by the InstrumentLoader. -#define INSTRUMENT_LOADER_QUEUE_SIZE 200 +#include namespace LinuxSampler { @@ -59,8 +58,9 @@ }; // Instance variables. - RingBuffer* pQueue; ///< queue with commands for loading new instruments. - Condition conditionJobsLeft; ///< synchronizer to block this thread until a new job arrives + std::list queue; ///< queue with commands for loading new instruments. + Mutex mutex; ///< for making the queue thread safe + Condition conditionJobsLeft; ///< synchronizer to block this thread until a new job arrives int Main(); ///< Implementation of virtual method from class Thread. };