From 319a4d0389ca7e4f8f885aef7564f7991d61142f Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Sun, 18 Aug 2013 21:18:43 +0200 Subject: [PATCH] * image.c (imagemagick_get_animation_cache): Don't segfault when pruning all entries. --- src/ChangeLog | 5 +++++ src/image.c | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index 671f6afc722..7ee41698bad 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2013-08-18 Lars Magne Ingebrigtsen + + * image.c (imagemagick_get_animation_cache): Don't segfault when + pruning all entries. + 2013-08-18 Ken Brown * sheap.c (STATIC_HEAP_SIZE): Adjust to current needs; use bigger diff --git a/src/image.c b/src/image.c index 198d5545c96..1452e8659b5 100644 --- a/src/image.c +++ b/src/image.c @@ -7932,9 +7932,10 @@ struct animation_cache * imagemagick_get_animation_cache (MagickWand *wand) { char *signature = xstrdup (MagickGetImageSignature (wand)); - struct animation_cache *cache = animation_cache; + struct animation_cache *cache; imagemagick_prune_animation_cache (); + cache = animation_cache; if (! cache) { -- 2.39.2