From 2277de02b932b0c685a832dbcdc224885decbb30 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan=20Dj=C3=A4rv?= Date: Fri, 13 Jul 2012 14:20:07 +0200 Subject: [PATCH] * image.c (Fimagemagick_types): Initialize ex with GetExceptionInfo and free it with DestroyExceptionInfo. Fixes: debbugs:11558 --- src/ChangeLog | 5 +++++ src/image.c | 7 ++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index 26019c1302d..9161d4c40de 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2012-07-13 Kalle Kankare (tiny change) + + * image.c (Fimagemagick_types): Initialize ex with GetExceptionInfo + and free it with DestroyExceptionInfo (Bug#11558). + 2012-07-13 Juanma Barranquero * s/ms-w32.h (FIRST_PTY_LETTER, HAVE_SOCKETS): Move to nt/config.nt. diff --git a/src/image.c b/src/image.c index 88d2f36cda9..6f2afb28cd2 100644 --- a/src/image.c +++ b/src/image.c @@ -7968,9 +7968,14 @@ and `imagemagick-types-inhibit'. */) Lisp_Object typelist = Qnil; size_t numf = 0; ExceptionInfo ex; - char **imtypes = GetMagickList ("*", &numf, &ex); + char **imtypes; size_t i; Lisp_Object Qimagemagicktype; + + GetExceptionInfo(&ex); + imtypes = GetMagickList ("*", &numf, &ex); + DestroyExceptionInfo(&ex); + for (i = 0; i < numf; i++) { Qimagemagicktype = intern (imtypes[i]); -- 2.39.2