[asterisk-bugs] [Asterisk 0018430]: Segfault when ExternalIVR() app. immediately sends S command due to race condition

Asterisk Bug Tracker noreply at bugs.digium.com
Tue Dec 7 13:46:06 CST 2010


The following issue has been set as RELATED TO issue 0017335. 
====================================================================== 
https://issues.asterisk.org/view.php?id=18430 
====================================================================== 
Reported By:                stevebrandli
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   18430
Category:                   Applications/app_externalivr
Reproducibility:            always
Severity:                   crash
Priority:                   normal
Status:                     new
Asterisk Version:           1.8.0 
JIRA:                        
Regression:                 No 
Reviewboard Link:            
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Request Review:              
====================================================================== 
Date Submitted:             2010-12-06 21:01 CST
Last Modified:              2010-12-07 13:46 CST
====================================================================== 
Summary:                    Segfault when ExternalIVR() app. immediately sends S
command due to race condition
Description: 
Segfault occurs if the ExternalIVR() application sends an S command faster
than the sound generator can setup and "play silence."  The segfault occurs
because the code believes it must send a T event but there are no sound
files current playing.

Entire extensions.conf:
[internal]
70,1,ExternalIVR(/var/lib/asterisk/agi-bin/fndatyivr.py)
70,n,Hangup()

Entire python script referenced above:
#!/usr/bin/python
import sys
import time
#time.sleep(1)
sys.stdout.write("S,/etc/asterisk/sounds/fndaty/WaitBrandli\n")
sys.stdout.flush()
time.sleep(10)

Just dial extension 70.  Notice the if the time.sleep(1) line in the
python script is uncommented, there is no problem.  I assume it is possible
that other setups will have trouble reproducing because application
execution takes longer.

Please consider relating issue https://issues.asterisk.org/view.php?id=17335.
======================================================================
Relationships       ID      Summary
----------------------------------------------------------------------
related to          0017335 ExternalIVR 'S' command sometimes resul...
====================================================================== 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2010-12-07 13:46 lmadsen        Relationship added       related to 0017335  
======================================================================




More information about the asterisk-bugs mailing list