[Asterisk-code-review] res_pjsip_pubsub: RLS 'uri' list attribute mismatch with SUBSCRIBE re... (asterisk[16])

Joshua Colp asteriskteam at digium.com
Tue Mar 15 06:24:44 CDT 2022


Attention is currently required from: Alexei Gradinari.
Joshua Colp has posted comments on this change. ( https://gerrit.asterisk.org/c/asterisk/+/18193 )

Change subject: res_pjsip_pubsub: RLS 'uri' list attribute mismatch with SUBSCRIBE request
......................................................................


Patch Set 3: Code-Review-1

(2 comments)

File res/res_pjsip_pubsub.c:

https://gerrit.asterisk.org/c/asterisk/+/18193/comment/afc3da1f_723294e8 
PS3, Line 1541: 	ast_sip_mod_data_set(dlg->pool, dlg->mod_data, pubsub_module.id, MOD_DATA_MSG,
You don't need to alter the function definition or retrieve the request URI in this function. The rdata is cloned onto the dialog itself for later use.


https://gerrit.asterisk.org/c/asterisk/+/18193/comment/f90bc7f3_f6d8364a 
PS3, Line 1282: 	pjsip_sip_uri_assign(tree->dlg->pool, sub->uri, resource_uri);
You can get access to the rdata here using:

pjsip_msg *rdata;
rdata = ast_sip_mod_data_get(tree->dlg->mod_data, pubsub_module.id, MOD_DATA_MSG);

And then the request URI using:

pjsip_sip_uri *request_uri;
request_uri = pjsip_uri_get_uri(rdata->msg_info.msg->line.req.uri);

Like normal.



-- 
To view, visit https://gerrit.asterisk.org/c/asterisk/+/18193
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: 16
Gerrit-Change-Id: I1fcfc08fd589677f40608c59a4e143c45ee05f6c
Gerrit-Change-Number: 18193
Gerrit-PatchSet: 3
Gerrit-Owner: Alexei Gradinari <alex2grad at gmail.com>
Gerrit-Reviewer: Friendly Automation
Gerrit-Reviewer: Joshua Colp <jcolp at sangoma.com>
Gerrit-Attention: Alexei Gradinari <alex2grad at gmail.com>
Gerrit-Comment-Date: Tue, 15 Mar 2022 11:24:44 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20220315/283329df/attachment.html>


More information about the asterisk-code-review mailing list