diff options
author | russell <russell@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-01-28 18:26:31 +0000 |
---|---|---|
committer | russell <russell@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-01-28 18:26:31 +0000 |
commit | fdeaaeb55e6d9e6a6f4e547e928bd011fe8a97c6 (patch) | |
tree | a2f57b347689716e70ce0fad9d0d7607e6960594 /res | |
parent | 20316375eaaec68699bf84026155ba6762c53bfe (diff) |
Fix a crash in ast_masq_park_call()
(issue #11342)
Reported by: DEA
Patches:
res_features-park.txt uploaded by DEA (license 3)
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@100626 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'res')
-rw-r--r-- | res/res_features.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/res/res_features.c b/res/res_features.c index 8842c0b9b..834ef0191 100644 --- a/res/res_features.c +++ b/res/res_features.c @@ -456,6 +456,7 @@ int ast_masq_park_call(struct ast_channel *rchan, struct ast_channel *peer, int { struct ast_channel *chan; struct ast_frame *f; + char *orig_chan_name = NULL; /* Make a new, fake channel that we'll use to masquerade in the real one */ if (!(chan = ast_channel_alloc(0, AST_STATE_DOWN, 0, 0, rchan->accountcode, rchan->exten, rchan->context, rchan->amaflags, "Parked/%s",rchan->name))) { @@ -476,7 +477,10 @@ int ast_masq_park_call(struct ast_channel *rchan, struct ast_channel *peer, int if (f) ast_frfree(f); - ast_park_call(chan, peer, timeout, extout); + orig_chan_name = ast_strdupa(chan->name); + + park_call_full(chan, peer, timeout, extout, orig_chan_name); + return 0; } |