< Previous by Date Date Index Next by Date >
  Thread Index Next in Thread >

[reSIProcate] TransactionState seg fault, assert mDnsResult


Hi,

I believe there is a fatal bug in resip/stack/TransactionState.cxx that causes a null-pointer de-reference in certain error cases.

The stack trace is here:

resip::DnsResult::available (this=0x0) at DnsResult.cxx:147
#1  0x00000000005bfc1c in resip::TransactionState::processNoDnsResults (
    this=0x7ffff0044ce0) at TransactionState.cxx:1828
#2  0x00000000005c133b in resip::TransactionState::processTransportFailure (
    this=0x7ffff0044ce0, msg=<value optimized out>)
    at TransactionState.cxx:2002
#3  0x00000000005c2326 in resip::TransactionState::processClientNonInvite (
    this=0x7ffff0044ce0, msg=0x7ffff00458f0) at TransactionState.cxx:933
#4  0x00000000005c617a in resip::TransactionState::process (
    controller=<value optimized out>) at TransactionState.cxx:637

Refering to https://svn.resiprocate.org/viewsvn/resiprocate/main/resip/stack/TransactionState.cxx?annotate=8912
Line 1828: assert(mDnsResult->available() == DnsResult::Finished);
is invoked when mDnsResult is NULL.

BTW, in stack frame 2, I believe execution is really at line 1996 and the compiler has collapsed the code together.
The strange thing is that processNoDnsResults() is only called at line 1996 when mDnsResult is NULL.
Thus I believe the error is with the assert on line 1828, but not sure what correct fix is, and also not sure if this is a sign of a larger problem.

Any help/fixes appreciated.

Thanks,
Kennard