diff options
author | Corey Farrell <git@cfware.com> | 2018-03-07 15:36:17 -0500 |
---|---|---|
committer | Corey Farrell <git@cfware.com> | 2018-03-07 16:03:01 -0600 |
commit | c8a521b6c804d66abb367783dba75eecb16889a2 (patch) | |
tree | cd017f42216be9712f6b38cacffd8d6a67484844 /channels/chan_dahdi.c | |
parent | 9040057db38dbc3d8181a5405d13ed8c8083d438 (diff) |
Replace direct checks of option_debug with DEBUG_ATLEAST macro.
Checking option_debug directly is incorrect as it ignores file/module
specific debug settings. This system-wide change replaces nearly all
direct checks for option_debug with the DEBUG_ATLEAST macro.
Change-Id: Ic342d4799a945dbc40ac085ac142681094a4ebf0
Diffstat (limited to 'channels/chan_dahdi.c')
-rw-r--r-- | channels/chan_dahdi.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/channels/chan_dahdi.c b/channels/chan_dahdi.c index de2c15279..0579a5a36 100644 --- a/channels/chan_dahdi.c +++ b/channels/chan_dahdi.c @@ -15058,14 +15058,14 @@ retry: ast_mutex_lock(&p->lock); if (p->owner && !p->restartpending) { if (ast_channel_trylock(p->owner)) { - if (option_debug > 2) + if (DEBUG_ATLEAST(3)) ast_verbose("Avoiding deadlock\n"); /* Avoid deadlock since you're not supposed to lock iflock or pvt before a channel */ ast_mutex_unlock(&p->lock); ast_mutex_unlock(&iflock); goto retry; } - if (option_debug > 2) + if (DEBUG_ATLEAST(3)) ast_verbose("Softhanging up on %s\n", ast_channel_name(p->owner)); ast_softhangup_nolock(p->owner, AST_SOFTHANGUP_EXPLICIT); p->restartpending = 1; |