diff options
author | Robin Watts <Robin.Watts@artifex.com> | 2022-02-03 13:24:32 +0000 |
---|---|---|
committer | Robin Watts <Robin.Watts@artifex.com> | 2022-02-03 15:52:48 +0000 |
commit | 9c1ce06162999fc7f55ef34c1ededeaa74d97e24 (patch) | |
tree | 83044f9eb9c287f53c7f890a76af24a616560b22 /pcl | |
parent | 670dc3a77bd2890c0f699c00244fb28ad600adf3 (diff) | |
download | ghostpdl-9c1ce06162999fc7f55ef34c1ededeaa74d97e24.tar.gz |
Fix memory leak with PCL macros.
A PCL stream that does not complete the macro operation, can lead
to memory leaks. This was spotted due to a problem where catting
files in on Windows was failing to treat them as binary files,
resulting in them being truncated at the first Ctrl-Z char.
Diffstat (limited to 'pcl')
-rw-r--r-- | pcl/pcl/pctop.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/pcl/pcl/pctop.c b/pcl/pcl/pctop.c index 58a920008..ad4ebf4cc 100644 --- a/pcl/pcl/pctop.c +++ b/pcl/pcl/pctop.c @@ -605,6 +605,8 @@ pcl_impl_deallocate_interp_instance(pl_interp_implementation_t * impl /* ins /* 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->pcs.macro_definition, "pcl_deallocate_interp_instance"); + gs_free_object(mem, pcli, "pcl_deallocate_interp_instance(pcl_interp_instance_t)"); return 0; |