commit d56351b8d1622da86f436380599841e5d850a556
parent 3a11735f6d84cfd55d840965e23089ef74a3cd82
Author: Vincent Forest <vincent.forest@meso-star.com>
Date: Mon, 12 Dec 2022 14:38:38 +0100
planeto: fix a memory leak
The discrete distribution of wavelengths was not released
Diffstat:
1 file changed, 1 insertion(+), 0 deletions(-)
diff --git a/src/planeto/htrdr_planeto.c b/src/planeto/htrdr_planeto.c
@@ -504,6 +504,7 @@ planeto_release(ref_T* ref)
if(cmd->ground) RNGRD(ref_put(cmd->ground));
if(cmd->source) htrdr_planeto_source_ref_put(cmd->source);
if(cmd->cie) htrdr_ran_wlen_cie_xyz_ref_put(cmd->cie);
+ if(cmd->discrete) htrdr_ran_wlen_discrete_ref_put(cmd->discrete);
if(cmd->planck) htrdr_ran_wlen_planck_ref_put(cmd->planck);
if(cmd->octrees_storage) CHK(fclose(cmd->octrees_storage) == 0);
if(cmd->output && cmd->output != stdout) CHK(fclose(cmd->output) == 0);