From: Joshua Colp Date: Mon, 18 Jun 2007 18:13:03 +0000 (+0000) Subject: Set the peer name on the dialog to the one configured in sip.conf and NOT the usernam... X-Git-Tag: 1.2.20~43 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=dc41ce985728015e0868cfb08e7d28513e1af61f;p=thirdparty%2Fasterisk.git Set the peer name on the dialog to the one configured in sip.conf and NOT the username to be used for authentication attempts. (issue #9967 reported by achauvin) git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@69765 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/channels/chan_sip.c b/channels/chan_sip.c index 36e5aab240..868fe8c826 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -1893,7 +1893,7 @@ static int create_addr_from_peer(struct sip_pvt *r, struct sip_peer *peer) ast_log(LOG_DEBUG, "Setting NAT on VRTP to %d\n", (ast_test_flag(r, SIP_NAT) & SIP_NAT_ROUTE)); ast_rtp_setnat(r->vrtp, (ast_test_flag(r, SIP_NAT) & SIP_NAT_ROUTE)); } - ast_copy_string(r->peername, peer->username, sizeof(r->peername)); + ast_copy_string(r->peername, peer->name, sizeof(r->peername)); ast_copy_string(r->authname, peer->username, sizeof(r->authname)); ast_copy_string(r->username, peer->username, sizeof(r->username)); ast_copy_string(r->peersecret, peer->secret, sizeof(r->peersecret));