diff options
Diffstat (limited to 'intern/cycles/util/util_guarded_allocator.h')
-rw-r--r-- | intern/cycles/util/util_guarded_allocator.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/intern/cycles/util/util_guarded_allocator.h b/intern/cycles/util/util_guarded_allocator.h index 263199417c4..2df717253e3 100644 --- a/intern/cycles/util/util_guarded_allocator.h +++ b/intern/cycles/util/util_guarded_allocator.h @@ -42,7 +42,7 @@ void util_guarded_mem_free(size_t n); /* Guarded allocator for the use with STL. */ template <typename T> -class GuardedAllocator: public std::allocator<T> { +class GuardedAllocator : public std::allocator<T> { public: template<typename _Tp1> struct rebind { @@ -53,7 +53,8 @@ public: { util_guarded_mem_alloc(n * sizeof(T)); #ifdef WITH_BLENDER_GUARDEDALLOC - return (T*)MEM_mallocN(n * sizeof(T), "Cycles Alloc"); + (void)hint; + return (T*)MEM_mallocN_aligned(n * sizeof(T), 16, "Cycles Alloc"); #else return std::allocator<T>::allocate(n, hint); #endif |