Skip to content

Commit

Permalink
🐛 set threadpool's queue_size
Browse files Browse the repository at this point in the history
  • Loading branch information
fennecdjay committed Sep 26, 2023
1 parent 750ff22 commit 794ebb7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/threadpool.c
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ threadpool_t *new_threadpool(const uint32_t thread_count, const uint32_t queue_s
p->head = p->tail = p->active = 0;
p->shutdown = p->has_lock = p->has_cond = false;
p->started = 0;
p->queue_size = queue_size;
if(alloc(p, thread_count, queue_size) || !utils(p) ||
start(p, thread_count)) {
free_threadpool(p);
Expand Down

0 comments on commit 794ebb7

Please sign in to comment.