diff --git a/libsrc/general/table.hpp b/libsrc/general/table.hpp index 54f5be31..3c25c2b0 100644 --- a/libsrc/general/table.hpp +++ b/libsrc/general/table.hpp @@ -120,7 +120,7 @@ public: /// Creates fixed maximal element size table inline TABLE (const NgFlatArray & entrysizes) - : BASE_TABLE (NgFlatArray (entrysizes.Size(), const_cast(&entrysizes[BASE])), + : BASE_TABLE (NgFlatArray (entrysizes.Size(), entrysizes.Size() ? const_cast(&entrysizes[BASE]) : nullptr), sizeof(T)) { ; }