aboutsummaryrefslogtreecommitdiffstats
path: root/channels/chan_local.c
diff options
context:
space:
mode:
Diffstat (limited to 'channels/chan_local.c')
-rw-r--r--channels/chan_local.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/channels/chan_local.c b/channels/chan_local.c
index 835ae88de..710d7ebea 100644
--- a/channels/chan_local.c
+++ b/channels/chan_local.c
@@ -533,7 +533,7 @@ static int local_fixup(struct ast_channel *oldchan, struct ast_channel *newchan)
p->chan = newchan;
/* Do not let a masquerade cause a Local channel to be bridged to itself! */
- if (p->owner->_bridge == p->chan || p->chan->_bridge == p->owner) {
+ if (!ast_check_hangup(newchan) && (p->owner->_bridge == p->chan || p->chan->_bridge == p->owner)) {
ast_log(LOG_WARNING, "You can not bridge a Local channel to itself!\n");
ast_mutex_unlock(&p->lock);
ast_queue_hangup(newchan);