]> git.ipfire.org Git - thirdparty/asterisk.git/commit
res_pjsip_messaging.c: Misc cleanups and fixes. 43/3843/1
authorRichard Mudgett <rmudgett@digium.com>
Tue, 6 Sep 2016 16:46:16 +0000 (11:46 -0500)
committerRichard Mudgett <rmudgett@digium.com>
Wed, 7 Sep 2016 21:02:28 +0000 (16:02 -0500)
commit23d6ec7417c8ffb6a0f3bde115fc406dc534441f
treebae15d0edd2d1a1bcd6dac1db79e67111f1479bf
parent249a733c17b1bce7caf5db2d44eed5d4687a71aa
res_pjsip_messaging.c: Misc cleanups and fixes.

* Eliminated RAII_VAR in get_outbound_endpoint().

* Simplify update_to() coding.  However, this function can only be a NoOp
because the To string can only be a URI and not a name-address formatted
string.

* Simplify update_from() coding.  Also fixed a code path modifying the
from string when the caller could still want to use the original string.

* Fixed msg_data_create() incompletely removing the "pjsip:" to then add
back the "sip:" string if needed.  The code didn't handle the "pjsip:sip:"
case because it left the colon after pjsip in the string.

Change-Id: I68a09a665f6d4daa9eaa59069045ab69122e28db
res/res_pjsip_messaging.c