]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Set the Caller ID "tag" on peers even if remote party information is present.
authorMark Michelson <mmichelson@digium.com>
Tue, 12 Jun 2012 15:37:38 +0000 (15:37 +0000)
committerMark Michelson <mmichelson@digium.com>
Tue, 12 Jun 2012 15:37:38 +0000 (15:37 +0000)
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

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/10@368808 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_sip.c

index b4a49b9b9ae53880533ee80006840dec040bb75c..9a7911c355c74cbe4d8aa6f610dbcbee94d825aa 100644 (file)
@@ -16528,11 +16528,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);