2
0
Эх сурвалжийг харах

Fixed ThreadPool not removing unused threads

MarcoROG 8 жил өмнө
parent
commit
caab3c8c6b

+ 4 - 1
Source/BansheeUtility/Source/BsThreadPool.cpp

@@ -261,8 +261,11 @@ namespace bs
 
 		for(auto& thread : idleThreads)
 		{
-			if(i < limit)
+			if (i < limit)
+			{
 				mThreads.push_back(thread);
+				i++;
+			}
 			else
 				destroyThread(thread);
 		}