From ecd15a3396e00a3ca5c810a16ad4a9913401554a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alf-Andr=C3=A9=20Walla?= Date: Fri, 9 Aug 2024 14:47:45 +0200 Subject: [PATCH] Fix bug with seq_alloc_sequential not respecting a run-time disabled arena --- engine/src/script/script.cpp | 2 +- engine/src/script/script.hpp | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/engine/src/script/script.cpp b/engine/src/script/script.cpp index 56daec3..b87810f 100644 --- a/engine/src/script/script.cpp +++ b/engine/src/script/script.cpp @@ -548,7 +548,7 @@ gaddr_t Script::guest_alloc(gaddr_t bytes) gaddr_t Script::guest_alloc_sequential(gaddr_t bytes) { - return machine().arena().seq_alloc_aligned(bytes, 8); + return machine().arena().seq_alloc_aligned(bytes, 8, machine().memory.initial_rodata_end() != 0x0); } bool Script::guest_free(gaddr_t addr) diff --git a/engine/src/script/script.hpp b/engine/src/script/script.hpp index ce7ecdb..b453a94 100644 --- a/engine/src/script/script.hpp +++ b/engine/src/script/script.hpp @@ -523,6 +523,7 @@ template struct GuestObjects other.m_address = 0x0; other.m_count = 0u; } + GuestObjects& operator=(GuestObjects&& other) = delete; ~GuestObjects() {