Commit 535aa11b authored by Matthieu Schaller's avatar Matthieu Schaller
Browse files

Correctly reset the cell's sort flags when rebuilding.

parent 4a4aa459
......@@ -196,6 +196,9 @@ void space_rebuild_recycle_mapper(void *map_data, int num_elements,
c->xparts = NULL;
c->gparts = NULL;
c->sparts = NULL;
c->do_sub_sort = 0;
c->do_grav_sub_drift = 0;
c->do_sub_drift = 0;
if (s->gravity) bzero(c->multipole, sizeof(struct gravity_tensors));
for (int i = 0; i < 13; i++)
if (c->sort[i] != NULL) {
......@@ -1823,6 +1826,9 @@ void space_split_recursive(struct space *s, struct cell *c,
cp->super = NULL;
cp->super_hydro = NULL;
cp->super_gravity = NULL;
cp->do_sub_sort = 0;
cp->do_grav_sub_drift = 0;
cp->do_sub_drift = 0;
#ifdef SWIFT_DEBUG_CHECKS
cp->cellID = last_cell_id++;
#endif
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment