diff options
author | Richard Mudgett <rmudgett@digium.com> | 2012-04-20 16:23:01 +0000 |
---|---|---|
committer | Richard Mudgett <rmudgett@digium.com> | 2012-04-20 16:23:01 +0000 |
commit | 01194c581139eb19063700418ce2a1df0c69ef02 (patch) | |
tree | 744a7cd232b059dc39bfca4c41469e27aba91e66 /channels/chan_misdn.c | |
parent | b43f4a60ddf00ca242d95488bc31fd8ea7fc5b9f (diff) |
Use ast_channel_lock_both() where it was inlined before.
The CHANNEL_DEADLOCK_AVOIDANCE() feature of preserving where the channel
lock was originally obtained is overkill where ast_channel_lock_both() was
inlined.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@362888 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'channels/chan_misdn.c')
-rw-r--r-- | channels/chan_misdn.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/channels/chan_misdn.c b/channels/chan_misdn.c index de807774a..0f1715b7a 100644 --- a/channels/chan_misdn.c +++ b/channels/chan_misdn.c @@ -8560,10 +8560,7 @@ static int misdn_attempt_transfer(struct chan_list *active_ch, struct chan_list return -1; } - ast_channel_lock(held_ch->ast); - while (ast_channel_trylock(active_ch->ast)) { - CHANNEL_DEADLOCK_AVOIDANCE(held_ch->ast); - } + ast_channel_lock_both(held_ch->ast, active_ch->ast); transferee = ast_bridged_channel(held_ch->ast); if (!transferee) { |