[Home]

Summary:ASTERISK-15221: Asterisk is crashing on any H323 call.
Reporter:Dmitry Dudkin (ddv2005)Labels:
Date Opened:2009-11-26 10:21:00.000-0600Date Closed:2011-07-27 12:56:39
Priority:CriticalRegression?No
Status:Closed/CompleteComponents:Channels/chan_h323
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) backtrace.txt
Description:I have PWLIB 1.11.1 & OPENH323 1.19.0. When I use any Asterisk 1.4.x then H323 is work fine. But with Asterisk 1.6.1.X it is crashed in MyH323Connection::SetCapabilities on creating H323_UserInputCapability(H323_UserInputCapability::HookFlashH245);
======================================================================
#0  0x013e82bc in PFactory<OpalMediaFormat, PString>::WorkerBase::CreateInstance (this=0x715d9c, key=@0xb7d0e618)
   at /root/openh323/../pwlib/include/ptlib/pfactory.h:242
#1  0x013ec280 in PFactory<OpalMediaFormat, PString>::CreateInstance_Internal (
   this=0x87a6708, key=@0xb7d0e618)
   at /root/openh323/../pwlib/include/ptlib/pfactory.h:389
#2  0x013ec2ea in PFactory<OpalMediaFormat, PString>::CreateInstance (
   key=@0xb7d0e618) at /root/openh323/../pwlib/include/ptlib/pfactory.h:303
#3  0x0143f4ae in OpalMediaFormat (this=0xbbc7a78,
   fullName=0x15e0e68 "UserInput/RFC2833", dsid=1, pt=101, nj=1, bw=100,
   fs=4, ft=1200, tu=8, ts=0) at mediafmt.cxx:444
#4  0x013edc23 in OpalUserInputRFC2833Format (this=0xbbc7a78)
   at h323caps.cxx:1727
ASTERISK-1  0x013edc65 in PFactory<OpalMediaFormat, PString>::Worker<OpalUserInputRFC2833Format>::Create (this=0x15e2a70)
   at /root/openh323/../pwlib/include/ptlib/pfactory.h:270
ASTERISK-2  0x013e82f5 in PFactory<OpalMediaFormat, PString>::WorkerBase::CreateInstance (this=0x15e2a70, key=@0xb4332b48)
   at /root/openh323/../pwlib/include/ptlib/pfactory.h:245
ASTERISK-3  0x013ec280 in PFactory<OpalMediaFormat, PString>::CreateInstance_Internal (
   this=0x87a6708, key=@0xb4332b48)
   at /root/openh323/../pwlib/include/ptlib/pfactory.h:389
ASTERISK-4  0x013ec2ea in PFactory<OpalMediaFormat, PString>::CreateInstance (
---Type <return> to continue, or q <return> to quit---
   key=@0xb4332b48) at /root/openh323/../pwlib/include/ptlib/pfactory.h:303
ASTERISK-5  0x013deb8f in H323_UserInputCapability (this=0xbbc7a38,
   _subType=H323_UserInputCapability::HookFlashH245) at h323caps.cxx:1741
ASTERISK-6 0x039731ce in MyH323Connection::SetCapabilities ()
  from /usr/lib/asterisk/modules/chan_h323.so
ASTERISK-7 0x0397370c in h323_set_capabilities ()
  from /usr/lib/asterisk/modules/chan_h323.so
ASTERISK-8 0x0396599f in set_local_capabilities (call_reference=24029,
   token=0x886e070 "ip$localhost/24029") at chan_h323.c:2498
ASTERISK-9 0x0396ebdd in MyH323Connection::OnSetLocalCapabilities ()
  from /usr/lib/asterisk/modules/chan_h323.so
ASTERISK-10 0x03972474 in MyH323Connection::SendSignalSetup ()
  from /usr/lib/asterisk/modules/chan_h323.so
ASTERISK-11 0x013b7592 in H225CallThread::Main (this=0x886f5c0) at h323ep.cxx:936
ASTERISK-12 0x004a438a in PThread::PX_ThreadStart (arg=0x886f5c0) at tlibthrd.cxx:1338
ASTERISK-13 0x00a5b5ab in start_thread () from /lib/libpthread.so.0
ASTERISK-14 0x009b1cfe in clone () from /lib/libc.so.6
=================================================

I test it on 2 machines and same problem. After that I have installed fresh CentOS 5.4 in VMWARE and I reproduce this problem in the VMWARE.
Comments:By: Leif Madsen (lmadsen) 2009-12-01 12:37:28.000-0600

I can't seem to open your file. It is likely unable to be opened by anyone else as well. I don't see how your backtrace could be 114MB either, so could you reproduce this and attach backtrace files that are smaller, and not in an archive file? If it's not plaintext, it is unlikely any developers will open it.

By: Dmitry Dudkin (ddv2005) 2009-12-01 12:55:25.000-0600

I have added backtrace.txt

By: Russell Bryant (russell) 2009-12-03 17:29:37.000-0600

Unfortunately this is not a problem that we can fix.  The crash is down in the H323 stack, not in our code.

By: Dmitry Dudkin (ddv2005) 2009-12-03 17:37:36.000-0600

Is it mean that Asterisk 1.6.1 will never work with H323?
Crash is down in the H323 stack but same H323 stack (same binary libraries) work fine with Asterisk 1.4.27. It is mean that Asterisk 1.6.1 corrupt some global memory of H323 stack libraries and then it is down on it.

By: Dmitry Dudkin (ddv2005) 2009-12-03 17:42:08.000-0600

More that...It crash on creating CISCO_G726r32 capability that defined in asterisk\channels\h323\caps_h323.h. And it is your code. Problem is that the H323 codecs factory can't create capability that defined in Asterisk.

By: Dmitry Dudkin (ddv2005) 2009-12-03 17:50:22.000-0600

(gdb) print key
$1 = (class PString
    &) @0xb7d0e618: {<PCharArray> = {<PBaseArray<char>> = {<PAbstractArray> = {<PContainer> = {<PObject> = {_vptr.PObject = 0x574808},
         reference = 0xb7d0dc98}, elementSize = 1,
       theArray = 0xb7d0e5f8 "G726r32",
       allocatedDynamically = 1}, <No data fields>}, <No data fields>}, <No data fields>}

By: Leif Madsen (lmadsen) 2009-12-22 11:37:19.000-0600

It may be advantageous to try chan_ooh323 in the Addons menu of 1.6.2.0 as that is now being maintained, while chan_h323 is not well supported.

By: Russell Bryant (russell) 2011-07-27 12:56:33.201-0500

Per the Asterisk maintenance timeline page at http://www.asterisk.org/asterisk-versions maintenance (bug) support for the 1.4 and 1.6.x branches has ended. For continued maintenance support please move to the 1.8 branch which is a long term support (LTS) branch. For more information about branch support, please see https://wiki.asterisk.org/wiki/display/AST/Asterisk+Versions

If this is still an issue, please open a new issue so it can be re-triaged appropriately. Thanks!