diff options
Diffstat (limited to 'pjlib/src/pj/os_core_unix.c')
-rw-r--r-- | pjlib/src/pj/os_core_unix.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/pjlib/src/pj/os_core_unix.c b/pjlib/src/pj/os_core_unix.c index a28af657..0dbe0afe 100644 --- a/pjlib/src/pj/os_core_unix.c +++ b/pjlib/src/pj/os_core_unix.c @@ -1123,6 +1123,9 @@ PJ_DEF(pj_status_t) pj_mutex_trylock(pj_mutex_t *mutex) PJ_CHECK_STACK(); PJ_ASSERT_RETURN(mutex, PJ_EINVAL); + PJ_LOG(6,(mutex->obj_name, "Mutex: thread %s is trying", + pj_thread_this()->obj_name)); + status = pthread_mutex_trylock( &mutex->mutex ); if (status==0) { @@ -1138,6 +1141,9 @@ PJ_DEF(pj_status_t) pj_mutex_trylock(pj_mutex_t *mutex) PJ_LOG(6,(mutex->obj_name, "Mutex acquired by thread %s", pj_thread_this()->obj_name)); #endif + } else { + PJ_LOG(6,(mutex->obj_name, "Mutex: thread %s's trylock() failed", + pj_thread_this()->obj_name)); } if (status==0) |