Summary: | ASTERISK-11675: chan_isavail segfaulting asterisk after sip_hangup (introduced after #8556 changes) | ||
Reporter: | Caio Begotti (caio1982) | Labels: | |
Date Opened: | 2008-03-18 13:08:19 | Date Closed: | 2008-03-18 14:58:51 |
Priority: | Minor | Regression? | No |
Status: | Closed/Complete | Components: | Applications/app_chanisavail |
Versions: | Frequency of Occurrence | ||
Related Issues: | |||
Environment: | Attachments: | ( 0) bt_full.txt ( 1) bt_full2.txt | |
Description: | While testing a pristine copy of Asterisk before going after ASTERISK-11673 I've got a segfault when ast_hangup(tempchan) is called from app_chanisavail, which then calls sip_hangup and crash. It was introduced after the commits for ASTERISK-8320 (revision 108439). The problem seems to be lying under if (!p->alreadygone && !ast_strlen_zero(p->initreq.data->str)) though my friends and I are not completely sure. ****** ADDITIONAL INFORMATION ****** Tested with exten => 555,1,ChanIsAvail(SIP/999&SIP/000) | ||
Comments: | By: Caio Begotti (caio1982) 2008-03-18 13:11:04 Damn, I forgot to remove the optimization out. Reuploading bt full. By: Digium Subversion (svnbot) 2008-03-18 14:58:14 Repository: asterisk Revision: 109681 U trunk/channels/chan_sip.c ------------------------------------------------------------------------ r109681 | mmichelson | 2008-03-18 14:58:13 -0500 (Tue, 18 Mar 2008) | 7 lines Since a sip request's data field is now a stringfield, we not only have to check if the string is zero-length, but also if the data field is non-null. (closes issue ASTERISK-11675) Reported by: caio1982 ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=109681 By: Digium Subversion (svnbot) 2008-03-18 14:58:51 Repository: asterisk Revision: 109682 _U branches/1.6.0/ ------------------------------------------------------------------------ r109682 | mmichelson | 2008-03-18 14:58:50 -0500 (Tue, 18 Mar 2008) | 14 lines Blocked revisions 109681 via svnmerge ........ r109681 | mmichelson | 2008-03-18 15:02:26 -0500 (Tue, 18 Mar 2008) | 7 lines Since a sip request's data field is now a stringfield, we not only have to check if the string is zero-length, but also if the data field is non-null. (closes issue ASTERISK-11675) Reported by: caio1982 ........ ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=109682 |