]> git.ipfire.org Git - thirdparty/asterisk.git/commit
autoservice: Do not sleep if autoservice_stop is called within autoservice thread
authorAlexei Gradinari <alex2grad@gmail.com>
Wed, 4 Sep 2024 14:28:57 +0000 (10:28 -0400)
committerasterisk-org-access-app[bot] <120671045+asterisk-org-access-app[bot]@users.noreply.github.com>
Mon, 9 Sep 2024 23:17:20 +0000 (23:17 +0000)
commitc49b766f068d759fff1448ec07a032381cb2d845
treee79b131bd1ba8bf0ff47bbf5c85051c724bca98a
parent2f5b143b08c8559889affdec634b7fdd470e8b5e
autoservice: Do not sleep if autoservice_stop is called within autoservice thread

It's possible that ast_autoservice_stop is called within the autoservice thread.
In this case the autoservice thread is stuck in an endless sleep.

To avoid endless sleep ast_autoservice_stop must check that it's not called
within the autoservice thread.

Fixes: #763
main/autoservice.c