aboutsummaryrefslogtreecommitdiffstats
path: root/channel.c
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2006-08-05 09:01:37 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2006-08-05 09:01:37 +0000
commit7bf8a7b0fc2d043b2db0e64140f37ded4d4f2f34 (patch)
tree86107dea880b67189fc09ccc3919a7864825170a /channel.c
parentdcc9fb269c579b9e1fcf1e4e072c246c27988127 (diff)
Always generate a Newstate event in ast_setstate() instead of making it a
Newchannel event if the state was AST_STATE_DOWN. The Newchannel event will always be generated in ast_request(), so this just causes a duplicated Newchannel event in some cases. (issue #7506, repoted by capouch, fixed by me) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.2@38982 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channel.c')
-rw-r--r--channel.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/channel.c b/channel.c
index 830def796..738c6581b 100644
--- a/channel.c
+++ b/channel.c
@@ -3190,8 +3190,7 @@ int ast_setstate(struct ast_channel *chan, int state)
chan->_state = state;
ast_device_state_changed_literal(chan->name);
- manager_event(EVENT_FLAG_CALL,
- (oldstate == AST_STATE_DOWN) ? "Newchannel" : "Newstate",
+ manager_event(EVENT_FLAG_CALL, "Newstate",
"Channel: %s\r\n"
"State: %s\r\n"
"CallerID: %s\r\n"