mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-02 19:16:15 +00:00
Add initial simple threadpool test.
This one simply pushes a task into the threadpool and ensures that the listener gets the callbacks expected. It currently crashes, so I need to figure out what's wrong. git-svn-id: https://origsvn.digium.com/svn/asterisk/team/mmichelson/threadpool@377351 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -264,8 +264,6 @@ static void *threadpool_alloc(struct ast_taskprocessor_listener *listener)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
pool->tps = listener->tps;
|
||||
|
||||
ao2_ref(pool, +1);
|
||||
return pool;
|
||||
}
|
||||
@@ -624,6 +622,7 @@ struct ast_threadpool *ast_threadpool_create(struct ast_threadpool_listener *lis
|
||||
}
|
||||
|
||||
pool = tps_listener->private_data;
|
||||
pool->tps = tps;
|
||||
ast_threadpool_set_size(pool, initial_size);
|
||||
return pool;
|
||||
}
|
||||
|
Reference in New Issue
Block a user