[asterisk-commits] pjsip distributor.c: Use correct rdata info access method (P... (asterisk[master])

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Jun 1 18:15:53 CDT 2016


Joshua Colp has submitted this change and it was merged.

Change subject: pjsip_distributor.c: Use correct rdata info access method (Part 2).
......................................................................


pjsip_distributor.c: Use correct rdata info access method (Part 2).

The pjproject doxygen for rdata->msg_info.info says to call
pjsip_rx_data_get_info() instead of accessing the struct member directly.
You need to call the function mostly because the function will generate
the struct member value if it is not already setup.

Change-Id: I4d519385a577f3e9d9193a88125e493cf17fa799
---
M res/res_pjsip/pjsip_distributor.c
1 file changed, 3 insertions(+), 3 deletions(-)

Approvals:
  Mark Michelson: Looks good to me, approved
  Joshua Colp: Looks good to me, but someone else must approve; Verified



diff --git a/res/res_pjsip/pjsip_distributor.c b/res/res_pjsip/pjsip_distributor.c
index 0d3df06..3867eae 100644
--- a/res/res_pjsip/pjsip_distributor.c
+++ b/res/res_pjsip/pjsip_distributor.c
@@ -297,13 +297,13 @@
 
 	if (dlg) {
 		ast_debug(3, "Searching for serializer on dialog %s for %s\n",
-				dlg->obj_name, rdata->msg_info.info);
+			dlg->obj_name, pjsip_rx_data_get_info(rdata));
 		dist = pjsip_dlg_get_mod_data(dlg, distributor_mod.id);
 		if (dist) {
 			serializer = ao2_bump(dist->serializer);
 			if (serializer) {
 				ast_debug(3, "Found serializer %s on dialog %s\n",
-						ast_taskprocessor_name(serializer), dlg->obj_name);
+					ast_taskprocessor_name(serializer), dlg->obj_name);
 			}
 		}
 		pjsip_dlg_dec_lock(dlg);
@@ -313,7 +313,7 @@
 		/* We have a serializer so we know where to send the message. */
 	} else if (rdata->msg_info.msg->type == PJSIP_RESPONSE_MSG) {
 		ast_debug(3, "No dialog serializer for response %s. Using request transaction as basis\n",
-				rdata->msg_info.info);
+			pjsip_rx_data_get_info(rdata));
 		serializer = find_request_serializer(rdata);
 	} else if (!pjsip_method_cmp(&rdata->msg_info.msg->line.req.method, &pjsip_cancel_method)
 		|| !pjsip_method_cmp(&rdata->msg_info.msg->line.req.method, &pjsip_bye_method)) {

-- 
To view, visit https://gerrit.asterisk.org/2925
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I4d519385a577f3e9d9193a88125e493cf17fa799
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Owner: Richard Mudgett <rmudgett at digium.com>
Gerrit-Reviewer: Anonymous Coward #1000019
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Mark Michelson <mmichelson at digium.com>



More information about the asterisk-commits mailing list