From 59adf48a18c92dcdcf30b644370a55502875d9a7 Mon Sep 17 00:00:00 2001
From: Matthieu Schaller <schaller@strw.leidenuniv.nl>
Date: Tue, 15 Oct 2019 11:38:47 +0200
Subject: [PATCH] Also initialise the star_formation_part properties in
 space_init_parts and cell_dirft_part.

---
 src/cell.c  | 1 +
 src/space.c | 1 +
 2 files changed, 2 insertions(+)

diff --git a/src/cell.c b/src/cell.c
index 92f53d7ca8..9c88cc0fc6 100644
--- a/src/cell.c
+++ b/src/cell.c
@@ -4548,6 +4548,7 @@ void cell_drift_part(struct cell *c, const struct engine *e, int force) {
         hydro_init_part(p, &e->s->hs);
         chemistry_init_part(p, e->chemistry);
         pressure_floor_init_part(p, xp);
+        star_formation_init_part(p, e->star_formation);
         tracers_after_init(p, xp, e->internal_units, e->physical_constants,
                            with_cosmology, e->cosmology, e->hydro_properties,
                            e->cooling_func, e->time);
diff --git a/src/space.c b/src/space.c
index 61bce13947..8ff331883b 100644
--- a/src/space.c
+++ b/src/space.c
@@ -4381,6 +4381,7 @@ void space_init_parts_mapper(void *restrict map_data, int count,
     hydro_init_part(&parts[k], hs);
     chemistry_init_part(&parts[k], e->chemistry);
     pressure_floor_init_part(&parts[k], &xparts[k]);
+    star_formation_init_part(&parts[k], e->star_formation);
     tracers_after_init(&parts[k], &xparts[k], e->internal_units,
                        e->physical_constants, with_cosmology, e->cosmology,
                        e->hydro_properties, e->cooling_func, e->time);
-- 
GitLab