[asterisk-bugs] [Asterisk 0016957]: [patch] Rogue Newchannel events for failed Originate calls

Asterisk Bug Tracker noreply at bugs.digium.com
Mon Apr 26 16:19:58 CDT 2010


A NOTE has been added to this issue. 
====================================================================== 
https://issues.asterisk.org/view.php?id=16957 
====================================================================== 
Reported By:                atis
Assigned To:                mmichelson
====================================================================== 
Project:                    Asterisk
Issue ID:                   16957
Category:                   Core/PBX
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     closed
Target Version:             1.6.1.20
Asterisk Version:           SVN 
JIRA:                       SWP-1019 
Regression:                 No 
Reviewboard Link:            
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Request Review:              
Resolution:                 fixed
Fixed in Version:           
====================================================================== 
Date Submitted:             2010-03-03 16:36 CST
Last Modified:              2010-04-26 16:19 CDT
====================================================================== 
Summary:                    [patch] Rogue Newchannel events for failed Originate
calls
Description: 
When using AMI Originate to unavailable device, there's NewChannel event
without following Hangup event. 

I traced this to ast_pbx_outgoing_cdr_failed() which creates new channel
for CDR posting purposes, however destroys without ast_hangup() sending
Hangup event. It could probably be fixed by replacing ast_channell_free()
with ast_hangup(), however in SVN trunk there's function for allocating
dummy channel instead. 

Attached patch that won't generate events for channels with empty names
(this is probably why there was check for empty name_fmt, however it's
impossible to call ast_channel_alloc with empty name_fmt.

Affected 1.6.1 and 1.6.2 and probably below. SVN trunk uses dummy channel,
so probably unaffected.
======================================================================
Relationships       ID      Summary
----------------------------------------------------------------------
has duplicate       0015291 [regression] Received invalid event tha...
====================================================================== 

---------------------------------------------------------------------- 
 (0120943) svnbot (reporter) - 2010-04-26 16:19
 https://issues.asterisk.org/view.php?id=16957#c120943 
---------------------------------------------------------------------- 
Repository: asterisk
Revision: 259036

_U  branches/1.6.0/
U   branches/1.6.0/main/channel.c

------------------------------------------------------------------------
r259036 | mmichelson | 2010-04-26 16:19:57 -0500 (Mon, 26 Apr 2010) | 26
lines

Merged revisions 259023 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/trunk

................
  r259023 | mmichelson | 2010-04-26 16:13:35 -0500 (Mon, 26 Apr 2010) | 19
lines
  
  Merged revisions 259018 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r259018 | mmichelson | 2010-04-26 16:03:08 -0500 (Mon, 26 Apr 2010) |
13 lines
    
    Prevent Newchannel manager events for dummy channels.
    
    No Newchannel manager event will be fired for channels that are
    allocated to not match a registered technology type. Thus bogus
    channels allocated solely for variable substitution or CDR
    operations do not result in a Newchannel event.
    
    (closes issue https://issues.asterisk.org/view.php?id=16957)
    Reported by: atis
    
    Review: https://reviewboard.asterisk.org/r/601
  ........
................

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=259036 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2010-04-26 16:19 svnbot         Checkin                                      
2010-04-26 16:19 svnbot         Note Added: 0120943                          
======================================================================




More information about the asterisk-bugs mailing list