Fix crash when answering after a transport error occurs.
authorJoshua Colp <jcolp@digium.com>
Fri, 23 Aug 2013 13:58:08 +0000 (13:58 +0000)
committerJoshua Colp <jcolp@digium.com>
Fri, 23 Aug 2013 13:58:08 +0000 (13:58 +0000)
commitb2a13e83dcb4958cccd5d314a1bb8bf25379cb51
treec25b3b961ab2c729ad3d53692d26d3e6ea5e9206
parentd12c79f78fac40099ae5a3ee359a925befa4f1f0
Fix crash when answering after a transport error occurs.

If a response to an initial incoming INVITE results in a transport error
the INVITE transaction is removed from the INVITE session. Any attempts
to answer the INVITE session after this results in a crash as it requires
the INVITE transaction to exist. This change explicitly locks the dialog
and checks to ensure that the INVITE transaction exists before answering.

(closes issue AST-1203)
Reported by: John Bigelow

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@397515 65c4cc65-6c06-0410-ace0-fbb531ad65f3
channels/chan_pjsip.c