[asterisk-bugs] [Asterisk 0013301]: [patch] AMI UpdateConfig -- When creating category, memory allocation failure in config.c

Asterisk Bug Tracker noreply at bugs.digium.com
Thu Dec 4 23:41:37 CST 2008


A NOTE has been added to this issue. 
====================================================================== 
http://bugs.digium.com/view.php?id=13301 
====================================================================== 
Reported By:                trevo
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   13301
Category:                   Core/General
Reproducibility:            always
Severity:                   crash
Priority:                   normal
Status:                     ready for review
Asterisk Version:           1.6.1-beta1 
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Disclaimer on File?:        N/A 
Request Review:              
====================================================================== 
Date Submitted:             2008-08-14 02:00 CDT
Last Modified:              2008-12-04 23:41 CST
====================================================================== 
Summary:                    [patch] AMI UpdateConfig -- When creating category,
memory allocation failure in config.c
Description: 
Follow this telnet log to reproduce.  When attempting to execute the second
block asterisk crashes and in the logs I see this error:
ERROR[28453]
/builddir/build/BUILD/asterisk-1.6.0-beta9/include/asterisk/utils.h: Memory
Allocation Failure in function ALLOC_COMMENT at line 129 of config.c


Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
Asterisk Call Manager/1.1
Action: login
Username: admin
Secret: admin
Events: off

Response: Success
Message: Authentication accepted

Action: UpdateConfig
SrcFilename: iax.conf
DstFilename: iax.tmp.conf
Reload: no
Action-000000: NewCat
Cat-000000: tmpcat

Connection closed by foreign host.
^ At this point asterisk dies
====================================================================== 

---------------------------------------------------------------------- 
 (0095830) svnbot (reporter) - 2008-12-04 23:41
 http://bugs.digium.com/view.php?id=13301#c95830 
---------------------------------------------------------------------- 
Repository: asterisk
Revision: 161181

U   trunk/main/config.c

------------------------------------------------------------------------
r161181 | tilghman | 2008-12-04 23:41:36 -0600 (Thu, 04 Dec 2008) | 11
lines

The first file should have a blank config filename in the structure, so
that
when a save occurs to a different filename, everything goes to the
alternate
filename, instead of appending to the original.  This is important for the
AMI command UpdateConfig.
(closes issue http://bugs.digium.com/view.php?id=13301)
 Reported by: trevo
 Patches: 
       20081113__bug13301.diff.txt uploaded by Corydon76 (license 14)
       20081113__bug13301__1.6.0.diff.txt uploaded by Corydon76 (license
14)
 Tested by: Corydon76, blitzrage

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

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

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2008-12-04 23:41 svnbot         Note Added: 0095830                          
======================================================================




More information about the asterisk-bugs mailing list