Menu

#521 Seg-Fault in Release version of Opal Code(ver: 3.14.2)

Development_Branch
closed-fixed
nobody
None
5
2015-02-24
2014-07-24
Sandeep
No

Hi,

I am new to Opal. I just loaded 3.14.2 (Stable -2) version of Opal with 2.14.2(stable-2) version of PTLib on CentOS (Version 6.5 , 32bit, g++ (GCC) 4.4.7 20120313 (Red Hat 4.4.7-4)), and ran a Sample/Console application.

For some reason, the Debug version of the application (and all other sample applications) run with no-problems, but the Release version of application crashes (Infact all sample applications are crashing at same point). There is a similar bug that I can see being reported in April of this year. That bug is not yet resolved.

PS:- Few other things I checked to see if the problem goes away. The results are same in all cases.
(1) I also tried Latest CVS version of Opal(3.15-alpha0), PTLib(2.15-alpha0).
(2) I also tried compiling with "-O" rather than "-O3" to see if some optimization is causing the crash.

My team expect this to be some Initialization issue. I would like to fix it myself, but as I am new to Opal I need some guidance to do so. Also, It may be that someone knows the fix, and can help directly.

This is the gd-backtrace:

(gdb) bt

0 0x003c8dbd in PHashTableInfo::GetElementAt(PObject const&) () from /usr/local/lib/libpt.so.2.14.2

1 0x00346606 in PConfig::GetString(PString const&, PString const&, PString const&) const ()

from /usr/local/lib/libpt.so.2.14.2

2 0x00342bc0 in PConfig::GetInteger(PString const&, PString const&, long) const () from /usr/local/lib/libpt.so.2.14.2

3 0x00361d69 in PConfig::GetInteger(PString const&, long) const () from /usr/local/lib/libpt.so.2.14.2

4 0x00cd9e05 in OpalRTPSession::OpalRTPSession(OpalMediaSession::Init const&) () from /usr/local/lib/libopal.so.3.14.2

5 0x00ce6b94 in PParamFactory<OpalMediaSession, OpalMediaSession::Init="" const&,="" PCaselessString="">::Worker<OpalRTPSession>::Create(OpalMediaSession::Init const&) const () from /usr/local/lib/libopal.so.3.14.2

6 0x00cfaabc in OpalRTPConnection::CreateMediaSession(unsigned int, OpalMediaType const&, PString const&) ()

from /usr/local/lib/libopal.so.3.14.2

7 0x00cfde43 in OpalRTPConnection::UseMediaSession(unsigned int, OpalMediaType const&, PString const&) ()

from /usr/local/lib/libopal.so.3.14.2

8 0x0104faa6 in H323Connection::CreateRealTimeLogicalChannel(H323Capability const&, H323Channel::Directions, unsigned int, H245_H2250LogicalChannelParameters const*) () from /usr/local/lib/libopal.so.3.14.2

9 0x010612e0 in H323RealTimeCapability::CreateChannel(H323Connection&, H323Channel::Directions, unsigned int, H245_H2250LogicalChannelParameters const*) const () from /usr/local/lib/libopal.so.3.14.2

10 0x01043e60 in H323Connection::OpenLogicalChannel(H323Capability const&, unsigned int, H323Channel::Directions) ()

from /usr/local/lib/libopal.so.3.14.2

11 0x0104c574 in H323Connection::SelectFastStartChannels(unsigned int, bool, bool) () from /usr/local/lib/libopal.so.3.14.2

12 0x01041ecb in H323Connection::OnSelectLogicalChannels() () from /usr/local/lib/libopal.so.3.14.2

13 0x01059057 in H323Connection::SendSignalSetup(PString const&, H323TransportAddress const&) ()

from /usr/local/lib/libopal.so.3.14.2

14 0x0104903a in H323Connection::SetUpConnection() () from /usr/local/lib/libopal.so.3.14.2

15 0x00c8ab96 in OpalCall::OnSetUp(OpalConnection&) () from /usr/local/lib/libopal.so.3.14.2

16 0x00c77da6 in OpalConnection::SetUpConnection() () from /usr/local/lib/libopal.so.3.14.2

17 0x00d018cf in OpalLocalConnection::SetUpConnection() () from /usr/local/lib/libopal.so.3.14.2

18 0x00c5bf16 in AsynchCallSetUp(PSafePtr<OpalConnection, PSafePtrBase="">) () from /usr/local/lib/libopal.so.3.14.2

19 0x00c647bc in PThread1Arg<PSafePtr<OpalConnection, PSafePtrBase=""> >::Main() () from /usr/local/lib/libopal.so.3.14.2

20 0x0036ccfa in PThread::PX_ThreadMain(void*) () from /usr/local/lib/libpt.so.2.14.2

21 0x00697b39 in start_thread () from /lib/libpthread.so.0

22 0x005dcd7e in clone () from /lib/libc.so.6

Discussion

  • Robert Jongbloed

    Ticket moved from /p/opalvoip/support-requests/18/

     
  • Robert Jongbloed

    • status: open --> closed-fixed
    • Group: v1.0_(example) --> Development_Branch
     
  • Robert Jongbloed

    This seemed to affect only some versions of the GNU compiler. I finally found a system that did it and investigated the problem. The crash made no sense at all, and stupid things like doing a cout made it go away!

    Anyway, took opportunity to completely revamp and update the PConfig on Unix code to more modern PTLib classes, and now the problem has been fixed.

     

Log in to post a comment.