mirror of
https://github.com/doitsujin/dxvk.git
synced 2025-01-31 14:52:11 +01:00
[dxvk] Fix potential iterator invalidation in deferClear/Discard
flushClears clears the deferred clear list, so we need to break out of the loop on that code path.
This commit is contained in:
parent
31063252eb
commit
9bdc491cb7
@ -1868,8 +1868,10 @@ namespace dxvk {
|
||||
entry.clearValue.depthStencil.stencil = clearValue.depthStencil.stencil;
|
||||
|
||||
return;
|
||||
} else if (entry.imageView->checkSubresourceOverlap(imageView))
|
||||
} else if (entry.imageView->checkSubresourceOverlap(imageView)) {
|
||||
this->flushClears(false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
m_deferredClears.push_back({ imageView, 0, clearAspects, clearValue });
|
||||
@ -1884,8 +1886,10 @@ namespace dxvk {
|
||||
entry.discardAspects |= discardAspects;
|
||||
entry.clearAspects &= ~discardAspects;
|
||||
return;
|
||||
} else if (entry.imageView->checkSubresourceOverlap(imageView))
|
||||
} else if (entry.imageView->checkSubresourceOverlap(imageView)) {
|
||||
this->flushClears(false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
m_deferredClears.push_back({ imageView, discardAspects });
|
||||
|
Loading…
x
Reference in New Issue
Block a user