unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
blob d5b3d0cdef8f4cfe9f0df31848e2c838b094c9a2 1097 bytes (raw)
name: gnu/packages/patches/xplanet-1.3.1-libimage_gif.c.patch 	 # note: path name is non-authoritative(*)

 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
 
diff -uNr xplanet-1.3.1/src/libimage/gif.c xplanet-1.3.1.new/src/libimage/gif.c
--- xplanet-1.3.1/src/libimage/gif.c	2013-02-17 01:07:47.000000000 +0530
+++ xplanet-1.3.1.new/src/libimage/gif.c	2020-03-28 22:15:24.444309199 +0530
@@ -21,7 +21,7 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
-
+#include <stdbool.h>
 #include <gif_lib.h>
 
 /*
@@ -178,8 +178,12 @@
 	    *BufferP++ = ColorMapEntry->Blue;
 	}
     }
-    
+
+#if GIFLIB_MAJOR >= 5
+    if (DGifCloseFile(GifFile, NULL) == GIF_ERROR) {
+#else
     if (DGifCloseFile(GifFile) == GIF_ERROR) {
+#endif
 	return(0);
     }
 
@@ -493,7 +497,11 @@
 static void QuitGifError(GifFileType *GifFile)
 {
     fprintf(stderr, "Error writing GIF file\n");
+#if GIFLIB_MAJOR >= 5
+    if (GifFile != NULL) EGifCloseFile(GifFile, NULL);
+#else
     if (GifFile != NULL) EGifCloseFile(GifFile);
+#endif
 }
 
 int 
@@ -589,7 +597,11 @@
 	Ptr += width;
     }
 
+#if GIFLIB_MAJOR >= 5
+    if (EGifCloseFile(GifFile, NULL) == GIF_ERROR)
+#else
     if (EGifCloseFile(GifFile) == GIF_ERROR)
+#endif
 
     {
 	QuitGifError(GifFile);

debug log:

solving d5b3d0cdef ...
found d5b3d0cdef in https://yhetil.org/guix-patches/20200330081929.GA7259@tulip/

applying [1/1] https://yhetil.org/guix-patches/20200330081929.GA7259@tulip/
diff --git a/gnu/packages/patches/xplanet-1.3.1-libimage_gif.c.patch b/gnu/packages/patches/xplanet-1.3.1-libimage_gif.c.patch
new file mode 100644
index 0000000000..d5b3d0cdef

1:17: trailing whitespace.
 
1:20: space before tab in indent.
 	    *BufferP++ = ColorMapEntry->Blue;
1:21: space before tab in indent.
 	}
1:23: trailing whitespace.
-    
1:30: space before tab in indent.
 	return(0);
Checking patch gnu/packages/patches/xplanet-1.3.1-libimage_gif.c.patch...
Applied patch gnu/packages/patches/xplanet-1.3.1-libimage_gif.c.patch cleanly.
warning: squelched 7 whitespace errors
warning: 12 lines add whitespace errors.

index at:
100644 d5b3d0cdef8f4cfe9f0df31848e2c838b094c9a2	gnu/packages/patches/xplanet-1.3.1-libimage_gif.c.patch

(*) Git path names are given by the tree(s) the blob belongs to.
    Blobs themselves have no identifier aside from the hash of its contents.^

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).