summaryrefslogtreecommitdiff
path: root/extra/evas/evas-1.7.5-giflib5.patch
blob: 48d1834c5441cf1a099d9d44b7ac6abadb550038 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
diff --git a/src/modules/loaders/gif/evas_image_load_gif.c b/src/modules/loaders/gif/evas_image_load_gif.c
index 18a6e23..e8cc562 100644
--- a/src/modules/loaders/gif/evas_image_load_gif.c
+++ b/src/modules/loaders/gif/evas_image_load_gif.c
@@ -684,7 +684,9 @@ evas_image_load_file_head_gif(Image_Entry *ie, const char *file, const char *key
    int                 h;
    int                 alpha;
    int                 loop_count = -1;
-
+#if GIFLIB_MAJOR >= 5
+   int                 err;
+#endif
    w = 0;
    h = 0;
    alpha = -1;
@@ -700,7 +702,11 @@ evas_image_load_file_head_gif(Image_Entry *ie, const char *file, const char *key
         return EINA_FALSE;
      }
 
+#if GIFLIB_MAJOR >= 5
+   gif = DGifOpenFileHandle(fd, &err);
+#else
    gif = DGifOpenFileHandle(fd);
+#endif
    if (!gif)
      {
         if (fd) close(fd);
@@ -826,6 +832,9 @@ evas_image_load_specific_frame(Image_Entry *ie, const char *file, int frame_inde
    GifFileType       *gif;
    Image_Entry_Frame *frame = NULL;
    Gif_Frame         *gif_frame = NULL;
+#if GIFLIB_MAJOR >= 5
+   int                err;
+#endif
 
 #ifndef __EMX__
    fd = open(file, O_RDONLY);
@@ -838,7 +847,11 @@ evas_image_load_specific_frame(Image_Entry *ie, const char *file, int frame_inde
         return EINA_FALSE;
      }
 
+#if GIFLIB_MAJOR >= 5
+   gif = DGifOpenFileHandle(fd, &err);
+#else
    gif = DGifOpenFileHandle(fd);
+#endif
    if (!gif)
      {
         if (fd) close(fd);
@@ -915,6 +928,9 @@ evas_image_load_file_data_gif(Image_Entry *ie, const char *file, const char *key
           {
              int           fd;
              GifFileType  *gif;
+#if GIFLIB_MAJOR >= 5
+             int           err;
+#endif
 
 #ifndef __EMX__
              fd = open(file, O_RDONLY);
@@ -927,7 +943,11 @@ evas_image_load_file_data_gif(Image_Entry *ie, const char *file, const char *key
                   return EINA_FALSE;
                }
 
+#if GIFLIB_MAJOR >= 5
+             gif = DGifOpenFileHandle(fd, &err);
+#else
              gif = DGifOpenFileHandle(fd);
+#endif
              if (!gif)
                {
                   if (fd) close(fd);
@@ -984,6 +1004,9 @@ evas_image_load_frame_duration_gif(Image_Entry *ie, const char *file, const int
    int                 remain_frames = frame_num;
    double              duration = 0;
    int                 frame_count = 0;
+#if GIFLIB_MAJOR >= 5
+   int                 err;
+#endif
 
    frame_count = ie->frame_count;
 
@@ -1000,7 +1023,11 @@ evas_image_load_frame_duration_gif(Image_Entry *ie, const char *file, const int
 #endif
    if (fd < 0) return -1;
 
+#if GIFLIB_MAJOR >= 5
+   gif = DGifOpenFileHandle(fd, &err);
+#else
    gif = DGifOpenFileHandle(fd);
+#endif
    if (!gif)
      {
         if (fd) close(fd);