From c6590ad07b384762fd90ee8852796ec681a69286 Mon Sep 17 00:00:00 2001 From: ameerj <52414509+ameerj@users.noreply.github.com> Date: Mon, 19 Dec 2022 22:40:50 -0500 Subject: scratch_buffer: Explicitly defing resize and resize_destructive functions resize keeps previous data intact when the buffer grows resize_destructive destroys the previous data when the buffer grows --- src/video_core/dma_pusher.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/video_core/dma_pusher.cpp') diff --git a/src/video_core/dma_pusher.cpp b/src/video_core/dma_pusher.cpp index d1f541bf5..322de2606 100644 --- a/src/video_core/dma_pusher.cpp +++ b/src/video_core/dma_pusher.cpp @@ -74,7 +74,7 @@ bool DmaPusher::Step() { } // Push buffer non-empty, read a word - command_headers.resize(command_list_header.size); + command_headers.resize_destructive(command_list_header.size); if (Settings::IsGPULevelHigh()) { memory_manager.ReadBlock(dma_get, command_headers.data(), command_list_header.size * sizeof(u32)); -- cgit v1.2.3