summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSlávek Banko <slavek.banko@axis.cz>2015-12-20 12:59:02 +0100
committerSlávek Banko <slavek.banko@axis.cz>2015-12-20 12:59:02 +0100
commit1becbbdcacf2ddab3eda4a23aada29dbe16f15b0 (patch)
treecda8b48b978012907aa3a660731d56249182351d
parent5fdf91b73be14ea616505bdd98c8002c94804172 (diff)
downloadlibksquirrel-1becbbdcacf2ddab3eda4a23aada29dbe16f15b0.tar.gz
libksquirrel-1becbbdcacf2ddab3eda4a23aada29dbe16f15b0.zip
Add support giflib 5.1
Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
-rw-r--r--kernel/kls_gif/fmt_codec_gif.cpp8
1 files changed, 7 insertions, 1 deletions
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"