summaryrefslogtreecommitdiff
path: root/channels/chan_sip.c
diff options
context:
space:
mode:
authorMark Michelson <mmichelson@digium.com>2012-06-12 15:46:48 +0000
committerMark Michelson <mmichelson@digium.com>2012-06-12 15:46:48 +0000
commit6bd3eb4995e57e8a18fb428df17545f7ec3d86b6 (patch)
treefde1c8aed9c209a377ce82cdee468f256d3f38f3 /channels/chan_sip.c
parentdef53014ec8a79ad5b325d2eb77409b1df3c5176 (diff)
Set the Caller ID "tag" on peers even if remote party information is present.
On incoming calls, we were setting the cid_tag on the dialog only if there was no remote party information (Remote-Party-ID or P-Asserted-Identity) present. The Caller ID tag is an invented parameter, though, and should be set no matter the circumstance. (closes issue ASTERISK-19859) Reported by Thomas Arimont (closes issue AST-884) Reported by Trey Blancher ........ Merged revisions 368807 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 368808 from http://svn.asterisk.org/svn/asterisk/branches/10 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@368809 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'channels/chan_sip.c')
-rw-r--r--channels/chan_sip.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index 274e9787d..58dd23acf 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -16797,11 +16797,12 @@ static enum check_auth_result check_peer_ok(struct sip_pvt *p, char *of,
}
if (!ast_strlen_zero(peer->cid_name))
ast_string_field_set(p, cid_name, peer->cid_name);
- if (!ast_strlen_zero(peer->cid_tag))
- ast_string_field_set(p, cid_tag, peer->cid_tag);
if (peer->callingpres)
p->callingpres = peer->callingpres;
}
+ if (!ast_strlen_zero(peer->cid_tag)) {
+ ast_string_field_set(p, cid_tag, peer->cid_tag);
+ }
ast_string_field_set(p, fullcontact, peer->fullcontact);
if (!ast_strlen_zero(peer->context)) {
ast_string_field_set(p, context, peer->context);