pictureviewer: compatibility with giflib-5.x

This commit is contained in:
Stefan Seyfried
2012-12-28 13:57:46 +01:00
committed by Thilo Graf
parent ce2e95cc5a
commit c9eafa208e

View File

@@ -59,8 +59,13 @@ int fh_gif_load(const char *name,unsigned char **buffer,int* /*xp*/,int* /*yp*/)
GifRecordType rt;
ColorMapObject *cmap;
int cmaps;
#if GIFLIB_MAJOR >= 5
int error;
gft=DGifOpenFileName(name, &error);
#else
gft=DGifOpenFileName(name);
#endif
if(gft==NULL) gflush;
do
{
@@ -128,8 +133,13 @@ int fh_gif_getsize(const char *name,int *x,int *y, int /*wanted_width*/, int /*w
GifByteType *extension;
int extcode;
GifRecordType rt;
#if GIFLIB_MAJOR >= 5
int error;
gft=DGifOpenFileName(name, &error);
#else
gft=DGifOpenFileName(name);
#endif
if(gft==NULL) gflush;
do
{