Browse Source

sparse_set: invoke release_sparse_pages before clearing the sparse array

Michele Caini 3 years ago
parent
commit
dc25c9c1a2
1 changed files with 1 additions and 0 deletions
  1. 1 0
      src/entt/entity/sparse_set.hpp

+ 1 - 0
src/entt/entity/sparse_set.hpp

@@ -294,6 +294,7 @@ protected:
 
 
     /*! @brief Erases all entities of a sparse set. */
     /*! @brief Erases all entities of a sparse set. */
     virtual void clear_all() {
     virtual void clear_all() {
+        release_sparse_pages();
         sparse.clear();
         sparse.clear();
         packed.clear();
         packed.clear();
         free_list = tombstone;
         free_list = tombstone;