[Asterisk-code-review] res_pjsip_refer: Always serialize calls to refer_progress_notify (asterisk[16])

Richard Mudgett asteriskteam at digium.com
Tue Feb 9 15:58:57 CST 2021


Richard Mudgett has posted comments on this change. ( https://gerrit.asterisk.org/c/asterisk/+/15400 )

Change subject: res_pjsip_refer: Always serialize calls to refer_progress_notify
......................................................................


Patch Set 1:

(2 comments)

https://gerrit.asterisk.org/c/asterisk/+/15400/1/res/res_pjsip_refer.c 
File res/res_pjsip_refer.c:

https://gerrit.asterisk.org/c/asterisk/+/15400/1/res/res_pjsip_refer.c@133 
PS1, Line 133: 			ast_log(LOG_WARNING, "Subscription %p was stepped on!", sub);
This warning can only be a debug message.  It is rather useless because if you get it you are about to crash.


https://gerrit.asterisk.org/c/asterisk/+/15400/1/res/res_pjsip_refer.c@566 
PS1, Line 566: 			if (ast_sip_push_task_serializer(attended->progress->serializer, refer_progress_notify, notification)) {
> > Why not use ast_sip_push_task()?  The same for the other places where you are using the new ast_si […]
There are three other places that push the notify.  Also you are already changing the timing if the call does not take place on the serializer.

In this case the progress serializer is created for this transfer and can only execute two functions.  The refer_progress_notify() and refer_progress_terminate() functions.  If the terminate happens then refer_progress_notify() exits as the subscription is gone.  If the refer_progress_notify() is transitioning the notification state to terminated then any subsequent calls are ignored as well.

Where you are using the new push function, it will always push the task to the progress serializer anyway.



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

Gerrit-Project: asterisk
Gerrit-Branch: 16
Gerrit-Change-Id: Idcf1934c4e873f2c82e2d106f8d9f040caf9fa1e
Gerrit-Change-Number: 15400
Gerrit-PatchSet: 1
Gerrit-Owner: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Friendly Automation
Gerrit-Reviewer: Richard Mudgett <rmudgett at digium.com>
Gerrit-Comment-Date: Tue, 09 Feb 2021 21:58:57 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: George Joseph <gjoseph at digium.com>
Comment-In-Reply-To: Richard Mudgett <rmudgett at digium.com>
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20210209/28674afc/attachment.html>


More information about the asterisk-code-review mailing list