diff options
author | Benoit Germain <benoit.germain@ubisoft.com> | 2025-03-12 09:37:38 +0100 |
---|---|---|
committer | Benoit Germain <benoit.germain@ubisoft.com> | 2025-03-12 09:37:38 +0100 |
commit | bd9289acc58b676f228c7fee5766761c1877b414 (patch) | |
tree | a1dbd165537c0135a485b198d2b33ad5ac0c2caf | |
parent | a2580b819c17fe2a65ffc2be1e2bc28d7b5470ec (diff) | |
download | lanes-bd9289acc58b676f228c7fee5766761c1877b414.tar.gz lanes-bd9289acc58b676f228c7fee5766761c1877b414.tar.bz2 lanes-bd9289acc58b676f228c7fee5766761c1877b414.zip |
Make gcc happy
-rw-r--r-- | unit_tests/embedded_tests.cpp | 2 | ||||
-rw-r--r-- | unit_tests/shared.h | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/unit_tests/embedded_tests.cpp b/unit_tests/embedded_tests.cpp index 470deab..d4794df 100644 --- a/unit_tests/embedded_tests.cpp +++ b/unit_tests/embedded_tests.cpp | |||
@@ -38,8 +38,8 @@ namespace | |||
38 | if (ptr) { | 38 | if (ptr) { |
39 | --sAllocCount; | 39 | --sAllocCount; |
40 | sAllocBytes -= osize; | 40 | sAllocBytes -= osize; |
41 | free(ptr); | ||
42 | sAllocs.erase(ptr); | 41 | sAllocs.erase(ptr); |
42 | free(ptr); | ||
43 | } | 43 | } |
44 | return nullptr; | 44 | return nullptr; |
45 | } else if (!ptr) // malloc | 45 | } else if (!ptr) // malloc |
diff --git a/unit_tests/shared.h b/unit_tests/shared.h index c7cdba5..8a84a94 100644 --- a/unit_tests/shared.h +++ b/unit_tests/shared.h | |||
@@ -26,6 +26,7 @@ class LuaState | |||
26 | LuaState& operator=(LuaState const&) = delete; | 26 | LuaState& operator=(LuaState const&) = delete; |
27 | LuaState& operator=(LuaState&& rhs_) noexcept { | 27 | LuaState& operator=(LuaState&& rhs_) noexcept { |
28 | L = std::exchange(rhs_.L, nullptr); | 28 | L = std::exchange(rhs_.L, nullptr); |
29 | return *this; | ||
29 | } | 30 | } |
30 | 31 | ||
31 | public: | 32 | public: |