mirror of
https://bitbucket.org/smil3y/katie.git
synced 2025-02-25 03:12:56 +00:00
avoid locks in QFutureInterface getters
Signed-off-by: Ivailo Monev <xakepa10@laimg.moc>
This commit is contained in:
parent
3048bf8887
commit
d18837a359
1 changed files with 0 additions and 2 deletions
|
@ -242,14 +242,12 @@ inline void QFutureInterface<T>::reportFinished(const T *result)
|
||||||
template <typename T>
|
template <typename T>
|
||||||
inline const T &QFutureInterface<T>::resultReference(int index) const
|
inline const T &QFutureInterface<T>::resultReference(int index) const
|
||||||
{
|
{
|
||||||
QMutexLocker lock(mutex());
|
|
||||||
return resultStore().resultAt(index).value();
|
return resultStore().resultAt(index).value();
|
||||||
}
|
}
|
||||||
|
|
||||||
template <typename T>
|
template <typename T>
|
||||||
inline const T *QFutureInterface<T>::resultPointer(int index) const
|
inline const T *QFutureInterface<T>::resultPointer(int index) const
|
||||||
{
|
{
|
||||||
QMutexLocker lock(mutex());
|
|
||||||
return resultStore().resultAt(index).pointer();
|
return resultStore().resultAt(index).pointer();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue