summaryrefslogtreecommitdiffstats
path: root/raul/List.h
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2007-02-10 01:44:16 +0000
committerDavid Robillard <d@drobilla.net>2007-02-10 01:44:16 +0000
commit042ae95935253f5e41d5c29313296280aeabeb35 (patch)
tree7c15e1c85a83954084d59c1254b3e3ca126514b6 /raul/List.h
parent8140170f4b3fe308f346712a4bc93cdeecf55e8c (diff)
downloadraul-042ae95935253f5e41d5c29313296280aeabeb35.tar.gz
raul-042ae95935253f5e41d5c29313296280aeabeb35.tar.bz2
raul-042ae95935253f5e41d5c29313296280aeabeb35.zip
Fix previous (broken) commit.
git-svn-id: http://svn.drobilla.net/lad/raul@296 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'raul/List.h')
-rw-r--r--raul/List.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/raul/List.h b/raul/List.h
index 4d12a63..55959a1 100644
--- a/raul/List.h
+++ b/raul/List.h
@@ -76,7 +76,12 @@ public:
void push_back(T& elem); // NOT realtime safe
void clear();
- size_t size() const { return _size; }
+
+ /// Valid only in the write thread
+ unsigned size() const { return (unsigned)_size.get(); }
+
+ /// Valid for any thread
+ bool empty() { return (_head.get() != NULL); }
class iterator;