Fix infinite loop
This commit is contained in:
parent
fa6d026edc
commit
982d28cace
|
|
@ -27,9 +27,11 @@ namespace Nz
|
||||||
std::size_t poolCount = m_descriptorPools.size();
|
std::size_t poolCount = m_descriptorPools.size();
|
||||||
if (poolCount >= 2 && m_descriptorPools.back().freeBindings.TestAll())
|
if (poolCount >= 2 && m_descriptorPools.back().freeBindings.TestAll())
|
||||||
{
|
{
|
||||||
for (std::size_t i = poolCount - 1; i > 0; ++i)
|
for (std::size_t i = poolCount - 1; i > 0; --i)
|
||||||
{
|
{
|
||||||
if (m_descriptorPools[i].freeBindings.TestAll())
|
if (!m_descriptorPools[i].freeBindings.TestAll())
|
||||||
|
break;
|
||||||
|
|
||||||
poolCount--;
|
poolCount--;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -27,9 +27,11 @@ namespace Nz
|
||||||
std::size_t poolCount = m_descriptorPools.size();
|
std::size_t poolCount = m_descriptorPools.size();
|
||||||
if (poolCount >= 2 && m_descriptorPools.back().freeBindings.TestAll())
|
if (poolCount >= 2 && m_descriptorPools.back().freeBindings.TestAll())
|
||||||
{
|
{
|
||||||
for (std::size_t i = poolCount - 1; i > 0; ++i)
|
for (std::size_t i = poolCount - 1; i > 0; --i)
|
||||||
{
|
{
|
||||||
if (m_descriptorPools[i].freeBindings.TestAll())
|
if (!m_descriptorPools[i].freeBindings.TestAll())
|
||||||
|
break;
|
||||||
|
|
||||||
poolCount--;
|
poolCount--;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue