mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-06 21:07:58 +02:00
* Allocate min threads
This commit is contained in:
parent
6e8775f2a9
commit
6b36229d3c
@ -851,6 +851,8 @@ end;
|
||||
|
||||
function TFPCustomSimpleThreadPool.AddTask(aTask: TThreadPoolTask): Boolean;
|
||||
begin
|
||||
While ThreadCount<MinThreads do
|
||||
FTaskList.AddThread;
|
||||
CheckQueuedTasks;
|
||||
Result:=DoAddTask(aTask);
|
||||
if (not Result) and QueueTasks then
|
||||
|
Loading…
Reference in New Issue
Block a user