From cc097e53e2b094cdcb302515a1ecd97ad71115cf Mon Sep 17 00:00:00 2001 From: wjr21 <wjr21@sussex.ac.uk> Date: Mon, 25 Apr 2022 21:44:18 +0100 Subject: [PATCH] fixed using uninitialised space params in gravity_props_init --- examples/main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/examples/main.c b/examples/main.c index bd8ac44575..df173031bf 100644 --- a/examples/main.c +++ b/examples/main.c @@ -1315,11 +1315,12 @@ int main(int argc, char *argv[]) { /* Initialise the gravity properties */ bzero(&gravity_properties, sizeof(struct gravity_props)); if (with_self_gravity) + /* NOTE: In the zoom branch cdim is yet to be set by this point */ gravity_props_init(&gravity_properties, params, &prog_const, &cosmo, with_cosmology, with_external_gravity, with_baryon_particles, with_DM_particles, with_neutrinos, with_DM_background_particles, periodic, - s.dim, s.cdim); + dim, s.cdim); /* Initialize the space with these data. */ if (myrank == 0) clocks_gettime(&tic); -- GitLab