mutex_protected: Return bool for operator==
This commit is contained in:
@@ -37,12 +37,12 @@ class mutex_protected : public boost::noncopyable {
|
|||||||
return value_;
|
return value_;
|
||||||
}
|
}
|
||||||
|
|
||||||
T operator==(const mutex_protected &value) const {
|
bool operator==(const mutex_protected &value) const {
|
||||||
QMutexLocker l(&mutex_);
|
QMutexLocker l(&mutex_);
|
||||||
return value == value_;
|
return value.value() == value_;
|
||||||
}
|
}
|
||||||
|
|
||||||
T operator==(const T value) const {
|
bool operator==(const T value) const {
|
||||||
QMutexLocker l(&mutex_);
|
QMutexLocker l(&mutex_);
|
||||||
return value == value_;
|
return value == value_;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user