mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-02 19:16:15 +00:00
Make the initial size of the threadpool part of the options passed in.
git-svn-id: https://origsvn.digium.com/svn/asterisk/team/mmichelson/threadpool@379123 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -828,7 +828,7 @@ struct pool_options_pair {
|
||||
|
||||
struct ast_threadpool *ast_threadpool_create(const char *name,
|
||||
struct ast_threadpool_listener *listener,
|
||||
int initial_size, const struct ast_threadpool_options *options)
|
||||
const struct ast_threadpool_options *options)
|
||||
{
|
||||
struct ast_taskprocessor *tps;
|
||||
RAII_VAR(struct ast_taskprocessor_listener *, tps_listener, NULL, ao2_cleanup);
|
||||
@@ -858,7 +858,7 @@ struct ast_threadpool *ast_threadpool_create(const char *name,
|
||||
ao2_ref(listener, +1);
|
||||
pool->listener = listener;
|
||||
}
|
||||
ast_threadpool_set_size(pool, initial_size);
|
||||
ast_threadpool_set_size(pool, pool->options.initial_size);
|
||||
ao2_ref(pool, +1);
|
||||
return pool;
|
||||
}
|
||||
|
Reference in New Issue
Block a user