summaryrefslogtreecommitdiffstats
path: root/meta/recipes-extended/texinfo/texinfo/texinfo-4.12-zlib.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-extended/texinfo/texinfo/texinfo-4.12-zlib.patch')
-rw-r--r--meta/recipes-extended/texinfo/texinfo/texinfo-4.12-zlib.patch65
1 files changed, 44 insertions, 21 deletions
diff --git a/meta/recipes-extended/texinfo/texinfo/texinfo-4.12-zlib.patch b/meta/recipes-extended/texinfo/texinfo/texinfo-4.12-zlib.patch
index 41bd220bad..f25352c636 100644
--- a/meta/recipes-extended/texinfo/texinfo/texinfo-4.12-zlib.patch
+++ b/meta/recipes-extended/texinfo/texinfo/texinfo-4.12-zlib.patch
@@ -1,19 +1,22 @@
1From 20e1d8a9481dc13dd1d4d168b90e0ed2ff097b98 Mon Sep 17 00:00:00 2001 1From fe4f00459601efe0cfa75d92749a32237800a530 Mon Sep 17 00:00:00 2001
2From: Jussi Kukkonen <jussi.kukkonen@intel.com> 2From: Edwin Plauchu <edwin.plauchu.camacho@intel.com>
3Date: Thu, 6 Aug 2015 14:29:57 +0300 3Date: Tue, 29 Nov 2016 12:27:17 -0600
4Subject: [PATCH] texinfo-4.12-zlib 4Subject: [PATCH] texinfo-4.12-zlib
5 5
6Upstream-Status: Pending 6Upstream-Status: Pending
7
8Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
9Signed-off-by: Edwin Plauchu <edwin.plauchu.camacho@intel.com>
7--- 10---
8 install-info/Makefile.in | 2 +- 11 install-info/Makefile.in | 12 ++-----
9 install-info/install-info.c | 67 +++++++++++++++++++++++++++------------------ 12 install-info/install-info.c | 79 +++++++++++++++++++++++++++------------------
10 2 files changed, 42 insertions(+), 27 deletions(-) 13 2 files changed, 49 insertions(+), 42 deletions(-)
11 14
12diff --git a/install-info/Makefile.in b/install-info/Makefile.in 15diff --git a/install-info/Makefile.in b/install-info/Makefile.in
13index ad73abb..eaa2153 100644 16index 837d020..ba96579 100644
14--- a/install-info/Makefile.in 17--- a/install-info/Makefile.in
15+++ b/install-info/Makefile.in 18+++ b/install-info/Makefile.in
16@@ -241,7 +241,7 @@ am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(bindir)" 19@@ -216,7 +208,7 @@ am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(bindir)"
17 PROGRAMS = $(bin_PROGRAMS) 20 PROGRAMS = $(bin_PROGRAMS)
18 am_ginstall_info_OBJECTS = install-info.$(OBJEXT) 21 am_ginstall_info_OBJECTS = install-info.$(OBJEXT)
19 ginstall_info_OBJECTS = $(am_ginstall_info_OBJECTS) 22 ginstall_info_OBJECTS = $(am_ginstall_info_OBJECTS)
@@ -23,7 +26,7 @@ index ad73abb..eaa2153 100644
23 ginstall_info_DEPENDENCIES = $(top_builddir)/gnulib/lib/libgnu.a \ 26 ginstall_info_DEPENDENCIES = $(top_builddir)/gnulib/lib/libgnu.a \
24 $(am__DEPENDENCIES_1) 27 $(am__DEPENDENCIES_1)
25diff --git a/install-info/install-info.c b/install-info/install-info.c 28diff --git a/install-info/install-info.c b/install-info/install-info.c
26index b454c15..4e39122 100644 29index e58189c..8617787 100644
27--- a/install-info/install-info.c 30--- a/install-info/install-info.c
28+++ b/install-info/install-info.c 31+++ b/install-info/install-info.c
29@@ -22,6 +22,7 @@ 32@@ -22,6 +22,7 @@
@@ -43,7 +46,7 @@ index b454c15..4e39122 100644
43 open_possibly_compressed_file (char *filename, 46 open_possibly_compressed_file (char *filename,
44 void (*create_callback) (char *), 47 void (*create_callback) (char *),
45- char **opened_filename, char **compression_program) 48- char **opened_filename, char **compression_program)
46+ char **opened_filename, char **compression_program, int *is_pipe) 49+ char **opened_filename, char **compression_program, int *is_pipe)
47 { 50 {
48 char *local_opened_filename, *local_compression_program; 51 char *local_opened_filename, *local_compression_program;
49 int nread; 52 int nread;
@@ -119,7 +122,7 @@ index b454c15..4e39122 100644
119 if (!f) 122 if (!f)
120 return 0; 123 return 0;
121 } 124 }
122@@ -767,12 +768,12 @@ open_possibly_compressed_file (char *filename, 125@@ -767,26 +768,26 @@ open_possibly_compressed_file (char *filename,
123 126
124 /* Read first few bytes of file rather than relying on the filename. 127 /* Read first few bytes of file rather than relying on the filename.
125 If the file is shorter than this it can't be usable anyway. */ 128 If the file is shorter than this it can't be usable anyway. */
@@ -128,14 +131,34 @@ index b454c15..4e39122 100644
128+ nread = gzread (f, data, sizeof (data)); 131+ nread = gzread (f, data, sizeof (data));
129+ if (nread != sizeof (data)) 132+ if (nread != sizeof (data))
130 { 133 {
131 /* Empty files don't set errno. Calling code can check for
132 this, so make sure errno == 0 just in case it isn't already. */
133- if (nread == 0) 134- if (nread == 0)
134+ if (nread >= 0) 135+ if (nread >= 0)
135 errno = 0; 136 {
136 return 0; 137 /* Try to create the file if its empty. */
137 } 138- if (feof (f) && create_callback)
138@@ -838,35 +839,40 @@ open_possibly_compressed_file (char *filename, 139+ if (gzeof(f) && create_callback)
140 {
141- if (fclose (f) != 0)
142+ if (gzclose(f) != 0)
143 return 0; /* unknown error closing file */
144
145- if (remove (filename) != 0)
146+ if (remove(filename) != 0)
147 return 0; /* unknown error deleting file */
148
149 (*create_callback) (filename);
150- f = fopen (*opened_filename, FOPEN_RBIN);
151+ f = gzopen (*opened_filename, FOPEN_RBIN);
152 if (!f)
153 return 0;
154- nread = fread (data, sizeof (data), 1, f);
155- if (nread == 0)
156+ nread = gzread(f, data, sizeof (data));
157+ if (nread >= 0)
158 return 0;
159 goto determine_file_type; /* success */
160 }
161@@ -857,35 +858,40 @@ determine_file_type:
139 *compression_program = NULL; 162 *compression_program = NULL;
140 163
141 /* Seek back over the magic bytes. */ 164 /* Seek back over the magic bytes. */
@@ -183,7 +206,7 @@ index b454c15..4e39122 100644
183 } 206 }
184 207
185 return f; 208 return f;
186@@ -885,7 +891,8 @@ readfile (char *filename, int *sizep, 209@@ -904,7 +910,8 @@ readfile (char *filename, int *sizep,
187 void (*create_callback) (char *), char **opened_filename, 210 void (*create_callback) (char *), char **opened_filename,
188 char **compression_program) 211 char **compression_program)
189 { 212 {
@@ -193,7 +216,7 @@ index b454c15..4e39122 100644
193 int filled = 0; 216 int filled = 0;
194 int data_size = 8192; 217 int data_size = 8192;
195 char *data = xmalloc (data_size); 218 char *data = xmalloc (data_size);
196@@ -893,14 +900,20 @@ readfile (char *filename, int *sizep, 219@@ -912,14 +919,20 @@ readfile (char *filename, int *sizep,
197 /* If they passed the space for the file name to return, use it. */ 220 /* If they passed the space for the file name to return, use it. */
198 f = open_possibly_compressed_file (filename, create_callback, 221 f = open_possibly_compressed_file (filename, create_callback,
199 opened_filename, 222 opened_filename,
@@ -216,7 +239,7 @@ index b454c15..4e39122 100644
216 if (nread < 0) 239 if (nread < 0)
217 return 0; 240 return 0;
218 if (nread == 0) 241 if (nread == 0)
219@@ -919,8 +932,10 @@ readfile (char *filename, int *sizep, 242@@ -938,8 +951,10 @@ readfile (char *filename, int *sizep,
220 /* We need to close the stream, since on some systems the pipe created 243 /* We need to close the stream, since on some systems the pipe created
221 by popen is simulated by a temporary file which only gets removed 244 by popen is simulated by a temporary file which only gets removed
222 inside pclose. */ 245 inside pclose. */
@@ -229,5 +252,5 @@ index b454c15..4e39122 100644
229 *sizep = filled; 252 *sizep = filled;
230 return data; 253 return data;
231-- 254--
2322.1.4 2552.9.3
233 256