fix pre-action crash (ryubing/ryujinx!236)

See merge request ryubing/ryujinx!236
This commit is contained in:
LotP
2025-12-12 14:28:54 -06:00
parent 3a593b6084
commit 2c0977f6b3
4 changed files with 18 additions and 6 deletions

View File

@@ -393,11 +393,16 @@ namespace Ryujinx.Graphics.Gpu.Memory
/// This will copy any buffer ranges designated for pre-flushing.
/// </summary>
/// <param name="syncpoint">True if the action is a guest syncpoint</param>
public void SyncPreAction(bool syncpoint)
public bool SyncPreAction(bool syncpoint)
{
if (_bufferInherited)
{
return true;
}
if (_referenceCount == 0)
{
return;
return false;
}
if (BackingState.ShouldChangeBacking())
@@ -414,6 +419,8 @@ namespace Ryujinx.Graphics.Gpu.Memory
_modifiedRanges?.GetRangesAtSync(Address, Size, _context.SyncNumber, _syncPreRangeAction);
}
}
return false;
}
void SyncPreRangeAction(ulong address, ulong size)