[asterisk-bugs] [Asterisk 0018975]: [patch] chan_misdn segfaults when DEBUG_THREADS is enabled 1.8.4-rc4

Asterisk Bug Tracker noreply at bugs.digium.com
Thu Mar 31 15:12:36 CDT 2011


A NOTE has been added to this issue. 
====================================================================== 
https://issues.asterisk.org/view.php?id=18975 
====================================================================== 
Reported By:                irroot
Assigned To:                rmudgett
====================================================================== 
Project:                    Asterisk
Issue ID:                   18975
Category:                   Channels/chan_misdn
Reproducibility:            always
Severity:                   crash
Priority:                   normal
Status:                     closed
Asterisk Version:           1.8.2.4 
JIRA:                        
Regression:                 No 
Reviewboard Link:           https://reviewboard.asterisk.org/r/1145 
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Request Review:              
Resolution:                 fixed
Fixed in Version:           
====================================================================== 
Date Submitted:             2011-03-15 09:16 CDT
Last Modified:              2011-03-31 15:12 CDT
====================================================================== 
Summary:                    [patch] chan_misdn segfaults when DEBUG_THREADS is
enabled 1.8.4-rc4
Description: 
This has caused me much frustration and pain will post a simple 1 line
patch to fix the problem.

when DEBUG_THREADS is enabled in 1.8.4-rc2 is enabled chan_misdn causes
asterisk to blow up this is related to mutex tracking somehow have a
trivial fix for it but not a reasonable explanation.
======================================================================
Relationships       ID      Summary
----------------------------------------------------------------------
related to          0018194 [patch] Loading chan_iax2.so allocates ...
====================================================================== 

---------------------------------------------------------------------- 
 (0133227) svnbot (reporter) - 2011-03-31 15:12
 https://issues.asterisk.org/view.php?id=18975#c133227 
---------------------------------------------------------------------- 
Repository: asterisk
Revision: 312023

_U  trunk/
U   trunk/channels/chan_misdn.c

------------------------------------------------------------------------
r312023 | rmudgett | 2011-03-31 15:12:35 -0500 (Thu, 31 Mar 2011) | 21
lines

Merged revisions 312022 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.8

........
  r312022 | rmudgett | 2011-03-31 15:11:40 -0500 (Thu, 31 Mar 2011) | 14
lines
  
  chan_misdn segfaults when DEBUG_THREADS is enabled.
  
  The segfault happens because jb->mutexjb is uninitialized from the
  ast_malloc().  The internals of ast_mutex_init() were assuming a nonzero
  value meant mutex tracking initialization had already happened.  Recent
  changes to mutex tracking code to reduce excessive memory consumption
  exposed this uninitialized value.
  
  Converted misdn_jb_init() to use ast_calloc() instead of ast_malloc().
  Also eliminated redundant zero initialization code in the routine.
  
  (closes issue https://issues.asterisk.org/view.php?id=18975)
  Reported by: irroot
........

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

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

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2011-03-31 15:12 svnbot         Note Added: 0133227                          
======================================================================




More information about the asterisk-bugs mailing list