aboutsummaryrefslogtreecommitdiffstats
path: root/src/alloc/secmem.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/alloc/secmem.h')
-rw-r--r--src/alloc/secmem.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/alloc/secmem.h b/src/alloc/secmem.h
index 7c27c8d3b..5ee374b6d 100644
--- a/src/alloc/secmem.h
+++ b/src/alloc/secmem.h
@@ -61,9 +61,10 @@ class secure_allocator
}
template<typename U, typename... Args>
- void
- construct(U* p, Args&&... args)
- { ::new((void *)p) U(std::forward<Args>(args)...); }
+ void construct(U* p, Args&&... args)
+ {
+ ::new(static_cast<void*>(p)) U(std::forward<Args>(args)...);
+ }
template<typename U> void destroy(U* p) { p->~U(); }