mirror of
https://github.com/stenzek/duckstation.git
synced 2026-02-04 05:04:33 +00:00
GPUBackend: Fix infinite loop on state allocation failure
This commit is contained in:
@@ -365,7 +365,7 @@ bool GPUBackend::AllocateMemorySaveStates(std::span<System::MemorySaveState> sta
|
||||
if (!backend->AllocateMemorySaveState(states[i], error))
|
||||
{
|
||||
// Free anything that was allocated.
|
||||
for (size_t j = 0; j <= i; i++)
|
||||
for (size_t j = 0; j <= i; j++)
|
||||
{
|
||||
states[j].state_data.deallocate();
|
||||
states[j].vram_texture.reset();
|
||||
|
||||
Reference in New Issue
Block a user