diff options
author | Armin Weatherwax | 2010-03-02 14:40:59 +0100 |
---|---|---|
committer | Armin Weatherwax | 2010-03-04 22:36:51 +0100 |
commit | 35c5041b506c959e455e67fab837cf6b99e5a2d0 (patch) | |
tree | 933e6b6ccedaba5930975c636425005a277ddf93 /linden/indra/llcommon/llthread.h | |
parent | Vex Streeter, Merov Linden: SNOW-434 Unsafe threaded op. (lltexturefetch.cpp). (diff) | |
download | meta-impy-35c5041b506c959e455e67fab837cf6b99e5a2d0.zip meta-impy-35c5041b506c959e455e67fab837cf6b99e5a2d0.tar.gz meta-impy-35c5041b506c959e455e67fab837cf6b99e5a2d0.tar.bz2 meta-impy-35c5041b506c959e455e67fab837cf6b99e5a2d0.tar.xz |
Robin Cornelius, Aleric Inglewood: SNOW-196 missing mutexes for texture fetch
Applys a trylock() abort system to allow the worker thread to avoid deadlocks
due to a race between mQueueMutex and mWorkerMutex.
Diffstat (limited to '')
-rw-r--r-- | linden/indra/llcommon/llthread.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/linden/indra/llcommon/llthread.h b/linden/indra/llcommon/llthread.h index 721b6e7..d773fa4 100644 --- a/linden/indra/llcommon/llthread.h +++ b/linden/indra/llcommon/llthread.h | |||
@@ -134,7 +134,8 @@ public: | |||
134 | void lock(); // blocks | 134 | void lock(); // blocks |
135 | void unlock(); | 135 | void unlock(); |
136 | bool isLocked(); // non-blocking, but does do a lock/unlock so not free | 136 | bool isLocked(); // non-blocking, but does do a lock/unlock so not free |
137 | 137 | bool tryLock(); //non-blocking, but not free, returns true if grabed lock | |
138 | |||
138 | protected: | 139 | protected: |
139 | apr_thread_mutex_t *mAPRMutexp; | 140 | apr_thread_mutex_t *mAPRMutexp; |
140 | apr_pool_t *mAPRPoolp; | 141 | apr_pool_t *mAPRPoolp; |