diff options
author | Julian Smith <julian.smith@artifex.com> | 2022-01-27 18:01:38 +0000 |
---|---|---|
committer | Robin Watts <Robin.Watts@artifex.com> | 2022-01-27 18:25:42 +0000 |
commit | a43476fd99a3f51ecf6e31927ee8be2471bb9e2d (patch) | |
tree | 02a9acbe4ecce436b486dcbbc4d352a3696814cd /pcl | |
parent | ed85943b3c1f2da666ad1fd8e21bcc324ba81875 (diff) | |
download | ghostpdl-a43476fd99a3f51ecf6e31927ee8be2471bb9e2d.tar.gz |
pcl/pcl/pctop.c: pcl_impl_deallocate_interp_instance(): fixed Memento leaks.
Added a call to pcl_pattern_free_pattern() with pcli->pcs.punsolid_pattern.
Fixes 114 leaked blocks with:
ghostpdl/mem-extract-bin/gpcl6 -dNOPAUSE -dBATCH -sDEVICE=ppmraw -dMaxBitmap=1000 -r300 -o gpcl6.out tests_private/customer_tests/bug689453.pcl
Diffstat (limited to 'pcl')
-rw-r--r-- | pcl/pcl/pctop.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/pcl/pcl/pctop.c b/pcl/pcl/pctop.c index 21d3fbeaa..ef6c488b9 100644 --- a/pcl/pcl/pctop.c +++ b/pcl/pcl/pctop.c @@ -598,6 +598,10 @@ pcl_impl_deallocate_interp_instance(pl_interp_implementation_t * impl /* ins gx_path_free(&pcli->pcs.g.polygon.buffer.path, "pcl_deallocate_interp_instance"); for (i = 0; i < sizeof(pcli->pcs.bi_pattern_array)/sizeof(*pcli->pcs.bi_pattern_array); i++) pcl_pattern_free_pattern(pcli->pcs.memory, pcli->pcs.bi_pattern_array[i], "destroy PCL pattern"); + + /* Fixed 114 leaked blocks with tests_private/customer_tests/bug689453.pcl. */ + pcl_pattern_free_pattern(pcli->pcs.memory, pcli->pcs.punsolid_pattern, "destroy PCL unsolid_pattern"); + gs_free_object(mem, pcli, "pcl_deallocate_interp_instance(pcl_interp_instance_t)"); return 0; |