From: Arnaud Giersch Date: Tue, 23 Oct 2012 11:24:03 +0000 (+0200) Subject: Call gap_remove in generic_update_actions_state_lazy too. X-Git-Tag: v3_8~24^2~1 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/baa92d18417cb91e2df78445d20c581999af0763?hp=05a2f271033bd32c4f81e9a1ae07e5456008f797;ds=sidebyside Call gap_remove in generic_update_actions_state_lazy too. *** Please double-check this commit ! *** Try to mimic what's done in generic_update_actions_state_full. Fixes an "use after free" error with smpi_replay. --- diff --git a/src/surf/surf_action.c b/src/surf/surf_action.c index 90d1878604..e05e199402 100644 --- a/src/surf/surf_action.c +++ b/src/surf/surf_action.c @@ -434,6 +434,9 @@ void generic_update_actions_state_lazy(double now, double delta, surf_model_t mo model->action_state_set((surf_action_t) action, SURF_ACTION_DONE); surf_action_lmm_heap_remove(model->model_private->action_heap,action); + + if (model->gap_remove && model == surf_network_model) + model->gap_remove(action); } } }