summaryrefslogtreecommitdiff
path: root/xps/xpstop.c
diff options
context:
space:
mode:
authorRobin Watts <Robin.Watts@artifex.com>2019-07-05 19:35:58 +0100
committerRobin Watts <Robin.Watts@artifex.com>2019-07-05 20:00:43 +0100
commitd181151975f0ee13162cc03865c0cc5f58931823 (patch)
tree9fbfb7c14e3b0e899ed6b65cb63c3aa408a58712 /xps/xpstop.c
parentf19453e0f1ced6eb0273f4eabc4e618553c49925 (diff)
downloadghostpdl-d181151975f0ee13162cc03865c0cc5f58931823.tar.gz
Fix memory leaks seen in XPS; pattern cache and start_part.
Diffstat (limited to 'xps/xpstop.c')
-rw-r--r--xps/xpstop.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/xps/xpstop.c b/xps/xpstop.c
index 7328e2241..b89ce574b 100644
--- a/xps/xpstop.c
+++ b/xps/xpstop.c
@@ -409,8 +409,10 @@ xps_impl_deallocate_interp_instance(pl_interp_implementation_t *impl)
rc_decrement_cs(ctx->srgb, "xps_impl_deallocate_interp_instance");
rc_decrement_cs(ctx->scrgb, "xps_impl_deallocate_interp_instance");
+ gx_pattern_cache_free(ctx->pgs->pattern_cache);
gs_gstate_free(ctx->pgs);
+ gs_free_object(mem, ctx->start_part, "xps_impl_deallocate_interp_instance");
gs_free_object(mem, ctx->fontdir, "xps_impl_deallocate_interp_instance");
gs_free_object(mem, ctx, "xps_impl_deallocate_interp_instance");
gs_free_object(mem, instance, "xps_impl_deallocate_interp_instance");