From: David Vossel Date: Tue, 22 Jun 2010 15:46:22 +0000 (+0000) Subject: fixes attended transfer behavior when both transferee and transferer hung up X-Git-Tag: 11.0.0-beta1~2802 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6d82dbb905b78360599194bbc5881342084d1972;p=thirdparty%2Fasterisk.git fixes attended transfer behavior when both transferee and transferer hung up If both the transferer and transferee of a attended transfer hangup before the new channel picks up, the new channel should be hung up as well as it has no endpoint to talk to. This mirrors the expected behavior used in 1.4. (closes issue #17444) Reported by: corruptor git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@271831 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/main/features.c b/main/features.c index fff94feebf..a973004bae 100644 --- a/main/features.c +++ b/main/features.c @@ -2117,6 +2117,11 @@ static int builtin_atxfer(struct ast_channel *chan, struct ast_channel *peer, st } else { /* Transferee hung up */ finishup(transferee); + /* At this point both the transferer transferee have hungup, + * so if newchan is up, hang it up as it has no one to talk to */ + if (newchan) { + ast_hangup(newchan); + } return -1; } }