Skip to content

Commit

Permalink
memory leaks
Browse files Browse the repository at this point in the history
  • Loading branch information
emiliobellini committed Jan 18, 2024
1 parent 0f2af6c commit ad9b792
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
9 changes: 7 additions & 2 deletions source/background.c
Original file line number Diff line number Diff line change
Expand Up @@ -2021,7 +2021,7 @@ int background_solve(
}

/** - perform the integration */
class_call(generic_evolver(background_derivs,
class_call_except(generic_evolver(background_derivs,
loga_ini,
loga_final,
pvecback_integration,
Expand All @@ -2038,7 +2038,12 @@ int background_solve(
NULL, //'print_variables' in evolver_rk could be set, but, not required
pba->error_message),
pba->error_message,
pba->error_message);
pba->error_message,
background_free_noinput(pba);
free(pvecback);
free(pvecback_integration);
free(used_in_output);
);

/** - recover some quantities today */
/* -> age in Gyears */
Expand Down
1 change: 1 addition & 0 deletions source/fourier.c
Original file line number Diff line number Diff line change
Expand Up @@ -1533,6 +1533,7 @@ int fourier_init(
pnw),
pfo->error_message,
pfo->error_message,
fourier_free(pfo);
fourier_hmcode_workspace_free(pfo,pnw);
for (index_pk=0; index_pk<pfo->pk_size; index_pk++){
free(pk_nl[index_pk]);
Expand Down

0 comments on commit ad9b792

Please sign in to comment.