summaryrefslogtreecommitdiff
path: root/main/features.c
diff options
context:
space:
mode:
Diffstat (limited to 'main/features.c')
-rw-r--r--main/features.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/main/features.c b/main/features.c
index 0224e7841..0f05fadf3 100644
--- a/main/features.c
+++ b/main/features.c
@@ -3012,7 +3012,13 @@ static int builtin_atxfer(struct ast_channel *chan, struct ast_channel *peer, st
ast_party_connected_line_free(&connected_line);
return -1;
}
- ast_explicit_goto(xferchan, ast_channel_context(transferee), ast_channel_exten(transferee), ast_channel_priority(transferee));
+
+ dash = strrchr(xferto, '@');
+ if (dash) {
+ /* Trim off the context. */
+ *dash = '\0';
+ }
+ ast_explicit_goto(xferchan, transferer_real_context, xferto, 1);
ast_channel_state_set(xferchan, AST_STATE_UP);
ast_clear_flag(ast_channel_flags(xferchan), AST_FLAGS_ALL);