]> git.ipfire.org Git - thirdparty/asterisk.git/commit
res_pjsip_exten_state,res_pjsip_mwi: Allow unload on shutdown
authorGeorge Joseph <gjoseph@sangoma.com>
Thu, 19 Oct 2023 13:40:26 +0000 (07:40 -0600)
committerasterisk-org-access-app[bot] <120671045+asterisk-org-access-app[bot]@users.noreply.github.com>
Fri, 20 Oct 2023 12:39:09 +0000 (12:39 +0000)
commitc32d090e772e7e598732332a23a41109072413da
tree82e5ff21469342b7c85c9677babf693248d64274
parentddb5c377fd54723a3a08b279b178d320eeae9319
res_pjsip_exten_state,res_pjsip_mwi: Allow unload on shutdown

Commit f66f77f last year prevents the res_pjsip_exten_state and
res_pjsip_mwi modules from unloading due to possible pjproject
asserts if the modules are reloaded. A side effect of the
implementation is that the taskprocessors these modules use aren't
being released. When asterisk is doing a graceful shutdown, it
waits AST_TASKPROCESSOR_SHUTDOWN_MAX_WAIT seconds for all
taskprocessors to stop but since those 2 modules don't release
theirs, the shutdown hangs for that amount of time.

This change allows the modules to be unloaded and their resources to
be released when ast_shutdown_final is true.

Resolves: #379
res/res_pjsip_exten_state.c
res/res_pjsip_mwi.c