summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2013-01-11 03:43:39 +0000
committerDavid Robillard <d@drobilla.net>2013-01-11 03:43:39 +0000
commit896f1e050b58557829f1523d466288f4fa2245a5 (patch)
treed7d38fb0fce5ef8634eb6629ddfcefb68a07ca8d
parentf8aa3ee7621758b35ba52a5b17972fa4144710ae (diff)
downloadraul-896f1e050b58557829f1523d466288f4fa2245a5.tar.gz
raul-896f1e050b58557829f1523d466288f4fa2245a5.tar.bz2
raul-896f1e050b58557829f1523d466288f4fa2245a5.zip
Initialise atomics.
Unlike the old Raul classes, std::atomic<T*> does not automatically initialise to NULL. git-svn-id: http://svn.drobilla.net/lad/trunk/raul@4917 a436a847-0d15-0410-975c-d299462d15a1
-rw-r--r--raul/Maid.hpp2
-rw-r--r--raul/SRMWQueue.hpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/raul/Maid.hpp b/raul/Maid.hpp
index 337d7f9..c64a1db 100644
--- a/raul/Maid.hpp
+++ b/raul/Maid.hpp
@@ -36,7 +36,7 @@ namespace Raul {
class Maid : public Noncopyable
{
public:
- Maid() {}
+ Maid() : _disposed(NULL) {}
inline ~Maid() {
cleanup();
diff --git a/raul/SRMWQueue.hpp b/raul/SRMWQueue.hpp
index 12b4b19..e122e57 100644
--- a/raul/SRMWQueue.hpp
+++ b/raul/SRMWQueue.hpp
@@ -77,7 +77,7 @@ private:
std::atomic<int> _write_space; ///< Remaining free space for new elements (all threads)
const unsigned _size; ///< Size of @ref _objects (you can store _size-1 objects)
- T* const _objects; ///< Fixed array containing queued elements
+ T* const _objects; ///< Fixed array containing queued elements
std::atomic<bool>* const _valid; ///< Parallel array to _objects, whether loc is written or not
};