From a8bb1eb39fe2cf62545798a493f6350c3d1d5728 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Fri, 20 Jul 2018 17:51:29 -0400 Subject: arm_test_common: Make file static variable a member variable of the testing environment Gets rid of file-static behavior. --- src/tests/core/arm/arm_test_common.cpp | 2 -- src/tests/core/arm/arm_test_common.h | 5 +++++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/tests/core/arm/arm_test_common.cpp b/src/tests/core/arm/arm_test_common.cpp index 7f9f27e19..2af487b6a 100644 --- a/src/tests/core/arm/arm_test_common.cpp +++ b/src/tests/core/arm/arm_test_common.cpp @@ -10,8 +10,6 @@ namespace ArmTests { -static Memory::PageTable* page_table = nullptr; - TestEnvironment::TestEnvironment(bool mutable_memory_) : mutable_memory(mutable_memory_), test_memory(std::make_shared(this)) { diff --git a/src/tests/core/arm/arm_test_common.h b/src/tests/core/arm/arm_test_common.h index 368f6f6c7..7fdbda494 100644 --- a/src/tests/core/arm/arm_test_common.h +++ b/src/tests/core/arm/arm_test_common.h @@ -11,6 +11,10 @@ #include "common/common_types.h" #include "core/memory_hook.h" +namespace Memory { +struct PageTable; +} + namespace ArmTests { struct WriteRecord { @@ -81,6 +85,7 @@ private: bool mutable_memory; std::shared_ptr test_memory; std::vector write_records; + Memory::PageTable* page_table = nullptr; }; } // namespace ArmTests -- cgit v1.2.3