returns if it cannot spawn a thread per each request. It returns before adding the request to the queue. Does that mean the server will ignore requests if it cannot spawn a thread at the time of arrival? If so, wouldnt it be better to queue it and hope for the availability of threads in the near future? Something like this thread_pool_addrequest() while ((thread_pool.total_threads - thread_pool.active_threads) < lrad_hash_table_num_elements(thread_pool.queue)) { if (spawn_thread(request->timestamp) == NULL) { radlog(L_INFO, "The maximum number of threads (%d) are active, cannot spawn new thread to handle request", thread_pool.max_threads); break; } }