summaryrefslogtreecommitdiff
path: root/base/gxpcmap.c
diff options
context:
space:
mode:
authorRobin Watts <Robin.Watts@artifex.com>2019-07-05 19:34:56 +0100
committerRobin Watts <Robin.Watts@artifex.com>2019-07-05 20:00:43 +0100
commite05305f8d8e6222250f18daf9b437b7faee8ebee (patch)
treef9bb5bec1fc60b30bf5591b5e51bbdd6fa6bb9f7 /base/gxpcmap.c
parentdd2bd7b4ca1886a4f3c58afbdacbb93831c57e1b (diff)
downloadghostpdl-e05305f8d8e6222250f18daf9b437b7faee8ebee.tar.gz
Destructors should cope with NULL.
Diffstat (limited to 'base/gxpcmap.c')
-rw-r--r--base/gxpcmap.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/base/gxpcmap.c b/base/gxpcmap.c
index 5b647bfe0..a05bab499 100644
--- a/base/gxpcmap.c
+++ b/base/gxpcmap.c
@@ -886,6 +886,8 @@ ensure_pattern_cache(gs_gstate * pgs)
void
gx_pattern_cache_free(gx_pattern_cache *pcache)
{
+ if (pcache == NULL)
+ return;
pattern_cache_free_all(pcache);
gs_free_object(pcache->memory, pcache->tiles, "gx_pattern_cache_free");
pcache->tiles = NULL;