Use QAtomicInt::store() instead of operator=(int)
... since the latter is now deprecated and will be removed. Change-Id: I456c1bf93ebf119c028bc4a63f1f8a31f069b83b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
This commit is contained in:
parent
d7649245ec
commit
768bc406f7
@ -388,7 +388,7 @@ bool QBasicMutex::lockInternal(int timeout)
|
||||
if (d_ptr.testAndSetAcquire(d, dummyLocked())) {
|
||||
// Mutex aquired
|
||||
Q_ASSERT(d->waiters.load() == -QMutexPrivate::BigNumber || d->waiters.load() == 0);
|
||||
d->waiters = 0;
|
||||
d->waiters.store(0);
|
||||
d->deref();
|
||||
return true;
|
||||
} else {
|
||||
@ -491,7 +491,7 @@ QMutexPrivate *QMutexPrivate::allocate()
|
||||
Q_ASSERT(!d->recursive);
|
||||
Q_ASSERT(!d->possiblyUnlocked.load());
|
||||
Q_ASSERT(d->waiters.load() == 0);
|
||||
d->refCount = 1;
|
||||
d->refCount.store(1);
|
||||
return d;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user