diff options
author | saturneric <[email protected]> | 2023-12-13 12:02:24 +0000 |
---|---|---|
committer | saturneric <[email protected]> | 2023-12-13 12:02:34 +0000 |
commit | d74765b42206a83c0ade8617e8100794eb169f37 (patch) | |
tree | 531352a75e4996c2a51cdb53b070515cd5596f53 /src/core/function/SecureMemoryAllocator.h | |
parent | fix: add some logs in setting channel object (diff) | |
download | GpgFrontend-d74765b42206a83c0ade8617e8100794eb169f37.tar.gz GpgFrontend-d74765b42206a83c0ade8617e8100794eb169f37.zip |
feat: mimalloc support valgrind
Diffstat (limited to 'src/core/function/SecureMemoryAllocator.h')
-rw-r--r-- | src/core/function/SecureMemoryAllocator.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/core/function/SecureMemoryAllocator.h b/src/core/function/SecureMemoryAllocator.h index 1475e258..a0905ba7 100644 --- a/src/core/function/SecureMemoryAllocator.h +++ b/src/core/function/SecureMemoryAllocator.h @@ -32,7 +32,7 @@ namespace GpgFrontend { -class GPGFRONTEND_CORE_EXPORT SecurityMemoryAllocator { +class GPGFRONTEND_CORE_EXPORT SecureMemoryAllocator { public: static auto Allocate(std::size_t) -> void *; @@ -45,9 +45,10 @@ template <typename T> struct SecureObjectDeleter { void operator()(T *ptr) { if (ptr) { - SPDLOG_TRACE("secure object deleter trys to free object, obj: {}", static_cast<void *>(ptr)); + SPDLOG_TRACE("secure object deleter trys to free object, obj: {}", + static_cast<void *>(ptr)); ptr->~T(); - SecurityMemoryAllocator::Deallocate(ptr); + SecureMemoryAllocator::Deallocate(ptr); } } }; |