From c9bc743ff10cd20512c3a18273c905183e742067 Mon Sep 17 00:00:00 2001 From: Jonathan Rose Date: Thu, 16 Aug 2012 18:57:27 +0000 Subject: [PATCH] chan_sip: Use pvt outgoing_call variable to set Remote-Party-ID Header Previously the pvt SIP_OUTGOING flag was used instead, which will frequently flip during reinvites. (closes issue AST-897) Reported by: Thomas Arimont git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@371357 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- channels/chan_sip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/channels/chan_sip.c b/channels/chan_sip.c index c9c90abf79..297d2caf5b 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -10999,7 +10999,7 @@ static int add_rpid(struct sip_request *req, struct sip_pvt *p) } add_header(req, "P-Asserted-Identity", ast_str_buffer(tmp)); } else { - ast_str_set(&tmp, -1, "\"%s\" ;party=%s", lid_name, lid_num, fromdomain, ast_test_flag(&p->flags[0], SIP_OUTGOING) ? "calling" : "called"); + ast_str_set(&tmp, -1, "\"%s\" ;party=%s", lid_name, lid_num, fromdomain, p->outgoing_call ? "calling" : "called"); switch (lid_pres) { case AST_PRES_ALLOWED_USER_NUMBER_NOT_SCREENED: