]> git.ipfire.org Git - thirdparty/asterisk.git/commit
chan_pjsip: Don't assume a session will have a channel.
authorJoshua Colp <jcolp@digium.com>
Sun, 12 Mar 2017 14:21:16 +0000 (14:21 +0000)
committerJoshua Colp <jcolp@digium.com>
Mon, 13 Mar 2017 18:37:47 +0000 (12:37 -0600)
commite237bb90aff6064aabfff047cbd00da51d4b8832
tree5b945785bdd3b4391a490f3ae06469899942f279
parent37a7e7596915bfc74469e398f2dfaf673baf9e93
chan_pjsip: Don't assume a session will have a channel.

When querying for PJSIP specific information using the dialplan
function CHANNEL() it is possible that the underlying session
will no longer have a channel associated with it. This is
most likely to occur when the RTCP HEP module attempts to get
the channel name. If this happens then a crash will occur.

This change just adds a check that the channel exists on the
session before querying it.

ASTERISK-26857

Change-Id: I113479cffff6ae64cf8ed089e9e1565223426f01
channels/pjsip/dialplan_functions.c