summaryrefslogtreecommitdiffstats
path: root/runtime/srUtils.h
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/srUtils.h')
-rw-r--r--runtime/srUtils.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/runtime/srUtils.h b/runtime/srUtils.h
index 16766312..6d5a784b 100644
--- a/runtime/srUtils.h
+++ b/runtime/srUtils.h
@@ -116,11 +116,13 @@ rsRetVal getFileSize(uchar *pszName, off_t *pSize);
if(bMustLock == LOCK_MUTEX) { \
pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, &iCancelStateSave); \
d_pthread_mutex_lock(mut); \
+ assert(bLockedOpIsLocked == 0); \
bLockedOpIsLocked = 1; \
}
#define END_MTX_PROTECTED_OPERATIONS(mut) \
if(bLockedOpIsLocked) { \
d_pthread_mutex_unlock(mut); \
+ bLockedOpIsLocked = 0; \
pthread_setcancelstate(iCancelStateSave, NULL); \
}