Fixed a bug that the training data generator crahses on memory allocation.

This commit is contained in:
nodchip
2020-08-08 18:21:38 +09:00
parent 2395833c07
commit ed4d007e3c
2 changed files with 2 additions and 2 deletions

View File

@@ -271,7 +271,7 @@ public:
template <typename U> AlignedAllocator(const AlignedAllocator<U>&) {}
T* allocate(std::size_t n) { return (T*)std_aligned_alloc(n * sizeof(T), alignof(T)); }
T* allocate(std::size_t n) { return (T*)std_aligned_alloc(alignof(T), n * sizeof(T)); }
void deallocate(T* p, std::size_t n) { std_aligned_free(p); }
};