Skip to content

Commit

Permalink
Added missing fix related to #2894 (0.x)
Browse files Browse the repository at this point in the history
  • Loading branch information
lminiero committed Feb 18, 2022
1 parent 14134ea commit 1c4b777
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mutex.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ typedef pthread_mutex_t janus_mutex;
/*! \brief Janus mutex try lock without debug */
#define janus_mutex_trylock_nodebug(a) { ret = !pthread_mutex_trylock(a); }
/*! \brief Janus mutex try lock with debug (prints the line that tried to lock a mutex) */
#define janus_mutex_trylock_debug(a) { JANUS_PRINT("[%s:%s:%d:trylock] %p\n", __FILE__, __FUNCTION__, __LINE__, a); ret = pthread_mutex_trylock(a); }
#define janus_mutex_trylock_debug(a) { JANUS_PRINT("[%s:%s:%d:trylock] %p\n", __FILE__, __FUNCTION__, __LINE__, a); ret = !pthread_mutex_trylock(a); }
/*! \brief Janus mutex try lock wrapper (selective locking debug) */
#define janus_mutex_trylock(a) ({ int ret; if(!lock_debug) { janus_mutex_trylock_nodebug(a); } else { janus_mutex_trylock_debug(a); } ret; })
/*! \brief Janus mutex unlock without debug */
Expand Down

0 comments on commit 1c4b777

Please sign in to comment.