aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael West <michael.west@ettus.com>2013-11-01 16:27:02 -0700
committerMichael West <michael.west@ettus.com>2013-11-01 16:27:02 -0700
commit39acb1ef1701671f47f8712320af351aa16050e3 (patch)
treed2475a8bb0220f7b588cd4ec6f7698819881fcc2
parentc3557962287aaf87090020113dc1de73d12fcfbe (diff)
downloaduhd-39acb1ef1701671f47f8712320af351aa16050e3.tar.gz
uhd-39acb1ef1701671f47f8712320af351aa16050e3.tar.bz2
uhd-39acb1ef1701671f47f8712320af351aa16050e3.zip
Changed reusable_barrier default size to 0 to make default behavior provide protection for multiple threads. Changed member initialization of other constructor.
-rw-r--r--host/include/uhd/utils/atomic.hpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/host/include/uhd/utils/atomic.hpp b/host/include/uhd/utils/atomic.hpp
index 5f0a056d2..55769d2fd 100644
--- a/host/include/uhd/utils/atomic.hpp
+++ b/host/include/uhd/utils/atomic.hpp
@@ -78,11 +78,9 @@ namespace uhd{
class UHD_API reusable_barrier{
public:
- reusable_barrier():_size (1) {}
+ reusable_barrier():_size (0) {}
- reusable_barrier(const size_t size) {
- _size = size;
- }
+ reusable_barrier(const size_t size):_size(size) {}
//! Resize the barrier for N threads
void resize(const size_t size){