mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-19 19:52:48 +00:00
Test that shutdown callback is called when expected.
git-svn-id: https://origsvn.digium.com/svn/asterisk/team/mmichelson/threadpool@376383 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -239,8 +239,16 @@ AST_TEST_DEFINE(taskprocessor_listener)
|
||||
goto test_exit;
|
||||
}
|
||||
|
||||
tps = ast_taskprocessor_unreference(tps);
|
||||
|
||||
if (!pvt->shutdown) {
|
||||
res = AST_TEST_FAIL;
|
||||
goto test_exit;
|
||||
}
|
||||
|
||||
test_exit:
|
||||
ao2_ref(listener, -1);
|
||||
/* This is safe even if tps is NULL */
|
||||
ast_taskprocessor_unreference(tps);
|
||||
return res;
|
||||
}
|
||||
|
Reference in New Issue
Block a user