diff options
author | Benoit Germain <benoit.germain@ubisoft.com> | 2025-04-29 12:56:49 +0200 |
---|---|---|
committer | Benoit Germain <benoit.germain@ubisoft.com> | 2025-04-29 12:56:49 +0200 |
commit | 313b2bbea87101fdd629a2a48b47c75d35b5c501 (patch) | |
tree | d333e8ad6ac03c4173742faa6c4bd60f5f10e905 | |
parent | d241ff31079ce49b34c5ac68d7d9a54ee5cbd028 (diff) | |
download | lanes-313b2bbea87101fdd629a2a48b47c75d35b5c501.tar.gz lanes-313b2bbea87101fdd629a2a48b47c75d35b5c501.tar.bz2 lanes-313b2bbea87101fdd629a2a48b47c75d35b5c501.zip |
Updated comments on unit test lanes.configure.allocator/protected
-rw-r--r-- | src/universe.hpp | 2 | ||||
-rw-r--r-- | unit_tests/init_and_shutdown.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/universe.hpp b/src/universe.hpp index 0c5e659..88a53a1 100644 --- a/src/universe.hpp +++ b/src/universe.hpp | |||
@@ -30,7 +30,7 @@ class ProtectedAllocator final | |||
30 | static void* protected_lua_Alloc(void* const ud_, void* const ptr_, size_t const osize_, size_t const nsize_) | 30 | static void* protected_lua_Alloc(void* const ud_, void* const ptr_, size_t const osize_, size_t const nsize_) |
31 | { | 31 | { |
32 | ProtectedAllocator* const allocator{ static_cast<ProtectedAllocator*>(ud_) }; | 32 | ProtectedAllocator* const allocator{ static_cast<ProtectedAllocator*>(ud_) }; |
33 | std::lock_guard<std::mutex> guard{ allocator->mutex }; | 33 | std::lock_guard<std::mutex> _guard{ allocator->mutex }; |
34 | return allocator->alloc(ptr_, osize_, nsize_); | 34 | return allocator->alloc(ptr_, osize_, nsize_); |
35 | } | 35 | } |
36 | 36 | ||
diff --git a/unit_tests/init_and_shutdown.cpp b/unit_tests/init_and_shutdown.cpp index f2de2a7..515a35a 100644 --- a/unit_tests/init_and_shutdown.cpp +++ b/unit_tests/init_and_shutdown.cpp | |||
@@ -195,7 +195,7 @@ TEST_CASE("lanes.configure.allocator/good_function") | |||
195 | 195 | ||
196 | // ################################################################################################# | 196 | // ################################################################################################# |
197 | 197 | ||
198 | // TODO: Investigate why this test crashes when unloading lanes_core.dll when running against Lua 5.1 and Lua 5.2 RELEASE ONLY! | 198 | // TODO: investigate why this test crashes under AppVerifier on lanes_core.dll unload when running against Lua 5.1, 5.2 and 5.4 RELEASE ONLY! |
199 | // apparently, the mutex of ProtectedAllocator is deemed still in use. Crash goes away if I don't use it in protected_lua_Alloc | 199 | // apparently, the mutex of ProtectedAllocator is deemed still in use. Crash goes away if I don't use it in protected_lua_Alloc |
200 | TEST_CASE(("lanes.configure.allocator/protected")) | 200 | TEST_CASE(("lanes.configure.allocator/protected")) |
201 | { | 201 | { |