[Asterisk-code-review] pjsip scheduler.c: Fix some corner cases. (asterisk[15])
Richard Mudgett
asteriskteam at digium.com
Mon Apr 9 18:25:50 CDT 2018
Richard Mudgett has uploaded a new patch set (#2). ( https://gerrit.asterisk.org/8749 )
Change subject: pjsip_scheduler.c: Fix some corner cases.
......................................................................
pjsip_scheduler.c: Fix some corner cases.
* Fix the periodic interval wander because it may take significant time
between the sched thread queueing the task in the serializer and the
serializer actually executing the task. The time it takes to actually
execute the task was already taken into account.
* Pass a schtd ref to the serializer when we queue a scheduled task on
the serializer. We don't want it going away on us while it is in the
serializer queue.
* Skip the scheduled task if the task was canceled between queueing the
task to the serializer and the serializer actually executing the task.
* Reorder struct ast_sip_sched_task to avoid unnecessary padding. Removed
task_id and added next_periodic.
* Hold a ref to the passed in serializer so the serializer cannot go away
on the scheduled task.
ASTERISK_26806
Change-Id: I6c8046b75f6953792c8c30e55b836a4291143f24
---
M include/asterisk/res_pjsip.h
M res/res_pjsip/pjsip_scheduler.c
2 files changed, 121 insertions(+), 46 deletions(-)
git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/49/8749/2
--
To view, visit https://gerrit.asterisk.org/8749
To unsubscribe, visit https://gerrit.asterisk.org/settings
Gerrit-Project: asterisk
Gerrit-Branch: 15
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I6c8046b75f6953792c8c30e55b836a4291143f24
Gerrit-Change-Number: 8749
Gerrit-PatchSet: 2
Gerrit-Owner: Richard Mudgett <rmudgett at digium.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20180409/29c29c47/attachment-0001.html>
More information about the asterisk-code-review
mailing list