From cbfc8a115af4cad55c15a2e3e3fe8691e74567dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sl=C3=A1vek=20Banko?= Date: Sun, 20 Dec 2015 12:59:02 +0100 Subject: Add support giflib 5.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Slávek Banko (cherry picked from commit 1becbbdcacf2ddab3eda4a23aada29dbe16f15b0) --- kernel/kls_gif/fmt_codec_gif.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'kernel/kls_gif') diff --git a/kernel/kls_gif/fmt_codec_gif.cpp b/kernel/kls_gif/fmt_codec_gif.cpp index 33d13e7..ad21d94 100644 --- a/kernel/kls_gif/fmt_codec_gif.cpp +++ b/kernel/kls_gif/fmt_codec_gif.cpp @@ -567,7 +567,13 @@ void fmt_codec::read_close() finfo.meta.clear(); finfo.image.clear(); - if(gif) DGifCloseFile(gif); + if(gif) { +#if defined(GIFLIB_MAJOR) && (GIFLIB_MAJOR > 5 || (GIFLIB_MAJOR == 5 && GIFLIB_MINOR >= 1)) + DGifCloseFile(gif, NULL); +#else + DGifCloseFile(gif); +#endif + } } #include "fmt_codec_cd_func.h" -- cgit v1.2.1