diff options
author | Robin Watts <robin.watts@artifex.com> | 2015-06-30 13:37:29 +0100 |
---|---|---|
committer | Robin Watts <robin.watts@artifex.com> | 2015-07-20 17:18:57 +0100 |
commit | 221915518d71c1ba3585addbe7cff49bba96f175 (patch) | |
tree | 5b6e33ebee8ed0d19b4b404405e7f4e5cce528b1 /source | |
parent | ee26ab550a27bd8764084f391f16fb5dbda3d325 (diff) | |
download | mupdf-221915518d71c1ba3585addbe7cff49bba96f175.tar.xz |
Bug 696061: Fix leak of xml block.
Bug 696061 showed GhostXPS crashing with a SEGV. Checking MuPDF
showed that a fix had already been applied here, but Memento
shows that the fix was causing a leak.
We therefore patch the leak here.
Diffstat (limited to 'source')
-rw-r--r-- | source/xps/xps-resource.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/source/xps/xps-resource.c b/source/xps/xps-resource.c index 712ed1cc..a625d13b 100644 --- a/source/xps/xps-resource.c +++ b/source/xps/xps-resource.c @@ -95,6 +95,8 @@ xps_parse_remote_resource_dictionary(fz_context *ctx, xps_document *doc, char *b dict = xps_parse_resource_dictionary(ctx, doc, part_uri, xml); if (dict) dict->base_xml = xml; /* pass on ownership */ + else + fz_drop_xml(ctx, xml); return dict; } |