make asterisk compile under devmode with DEBUG_THREADS enabled on OpenBSD

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@216435 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Michiel van Baak
2009-09-04 13:56:10 +00:00
parent da349b0e75
commit 8edfe07e6d
2 changed files with 3 additions and 3 deletions

View File

@@ -1027,7 +1027,7 @@ static inline int _ast_rwlock_timedrdlock(ast_rwlock_t *lock, const char *name,
do {
struct timeval _start = ast_tvnow(), _diff;
for (;;) {
if (!(res = pthread_rwlock_tryrdlock(&t->lock))) {
if (!(res = pthread_rwlock_tryrdlock(lock))) {
break;
}
_diff = ast_tvsub(ast_tvnow(), _start);
@@ -1076,7 +1076,7 @@ static inline int _ast_rwlock_timedwrlock(ast_rwlock_t *lock, const char *name,
do {
struct timeval _start = ast_tvnow(), _diff;
for (;;) {
if (!(res = pthread_rwlock_trywrlock(&t->lock))) {
if (!(res = pthread_rwlock_trywrlock(lock))) {
break;
}
_diff = ast_tvsub(ast_tvnow(), _start);