Compare commits

...

No commits in common. 'c9' and 'c10-beta' have entirely different histories.
c9 ... c10-beta

4
.gitignore vendored

@ -1 +1,3 @@
SOURCES/texinfo-6.7.tar.xz
SOURCES/fix-info-dir
SOURCES/info-6.5-sync-fix-info-dir.patch
SOURCES/texinfo-7.1.tar.xz

@ -1 +1,3 @@
d84d46368e2694919c05a539cb8c616ac89bf4df SOURCES/texinfo-6.7.tar.xz
97524a044cd04e1e947e0620425d94e8d1239bc4 SOURCES/fix-info-dir
6395e3cb1f421702de10459c73f4882b2226e7b4 SOURCES/info-6.5-sync-fix-info-dir.patch
1bb0fcde3d6bdaaabd620926d4648ac18956c03e SOURCES/texinfo-7.1.tar.xz

@ -1,40 +0,0 @@
diff -uNr texinfo-6.5.orig/contrib/fix-info-dir texinfo-6.5/contrib/fix-info-dir
--- texinfo-6.5.orig/contrib/fix-info-dir 2014-04-22 03:56:56.000000000 +0200
+++ texinfo-6.5/contrib/fix-info-dir 2018-02-04 13:48:35.979359350 +0100
@@ -163,29 +163,23 @@
{
### output the dir header
- echo "-*- Text -*-"
- echo "This file was generated automatically by $0."
- echo "This version was generated on `date`"
- echo "by `whoami`@`hostname` for `pwd`"
cat<<DIR_FILE_END_OF_FILE
-This is the file .../info/$DIR_FILE, which contains the topmost node of the
-Info hierarchy. The first time you invoke Info you start off
-looking at that node, which is ($DIR_FILE)Top.
-
+This is the file .../info/$DIR_FILE, which contains the
+topmost node of the Info hierarchy, called ($DIR_FILE)Top.
+The first time you invoke Info you start off looking at this node.

-File: $DIR_FILE Node: Top This is the top of the INFO tree
+File: $DIR_FILE, Node: Top This is the top of the INFO tree
This (the Directory node) gives a menu of major topics.
- Typing "q" exits, "?" lists all Info commands, "d" returns here,
+ Typing "q" exits, "H" lists all Info commands, "d" returns here,
"h" gives a primer for first-timers,
- "mEmacs<Return>" visits the Emacs topic, etc.
+ "mEmacs<Return>" visits the Emacs manual, etc.
In Emacs, you can click mouse button 2 on a menu item or cross reference
to select it.
-* Menu: The list of major topics begins on the next line.
-
+* Menu:
DIR_FILE_END_OF_FILE
### go through the list of files in the skeleton. If an info file

@ -1,236 +0,0 @@
diff -up texinfo-6.5.91/install-info/install-info.c.orig texinfo-6.5.91/install-info/install-info.c
--- texinfo-6.5.91/install-info/install-info.c.orig 2019-01-13 12:43:10.000000000 +0100
+++ texinfo-6.5.91/install-info/install-info.c 2019-01-14 09:31:45.322849494 +0100
@@ -19,6 +19,7 @@
#include <getopt.h>
#include <regex.h>
#include <argz.h>
+#include <zlib.h>
#define TAB_WIDTH 8
@@ -681,15 +682,15 @@ The first time you invoke Info you start
Return either stdin reading the file, or a non-stdin pipe reading
the output of the compression program. */
-FILE *
+void *
open_possibly_compressed_file (char *filename,
void (*create_callback) (char *),
- char **opened_filename, char **compression_program)
+ char **opened_filename, char **compression_program, int *is_pipe)
{
char *local_opened_filename, *local_compression_program;
int nread;
char data[13];
- FILE *f;
+ gzFile *f;
/* We let them pass NULL if they don't want this info, but it's easier
to always determine it. */
@@ -697,48 +698,48 @@ open_possibly_compressed_file (char *fil
opened_filename = &local_opened_filename;
*opened_filename = filename;
- f = fopen (*opened_filename, FOPEN_RBIN);
+ f = gzopen (*opened_filename, FOPEN_RBIN);
if (!f)
{
*opened_filename = concat (filename, ".gz", "");
- f = fopen (*opened_filename, FOPEN_RBIN);
+ f = gzopen (*opened_filename, FOPEN_RBIN);
}
if (!f)
{
free (*opened_filename);
*opened_filename = concat (filename, ".xz", "");
- f = fopen (*opened_filename, FOPEN_RBIN);
+ f = gzopen (*opened_filename, FOPEN_RBIN);
}
if (!f)
{
free (*opened_filename);
*opened_filename = concat (filename, ".bz2", "");
- f = fopen (*opened_filename, FOPEN_RBIN);
+ f = gzopen (*opened_filename, FOPEN_RBIN);
}
if (!f)
{
free (*opened_filename);
*opened_filename = concat (filename, ".lz", "");
- f = fopen (*opened_filename, FOPEN_RBIN);
+ f = gzopen (*opened_filename, FOPEN_RBIN);
}
if (!f)
{
free (*opened_filename);
*opened_filename = concat (filename, ".lzma", "");
- f = fopen (*opened_filename, FOPEN_RBIN);
+ f = gzopen (*opened_filename, FOPEN_RBIN);
}
#ifdef __MSDOS__
if (!f)
{
free (*opened_filename);
*opened_filename = concat (filename, ".igz", "");
- f = fopen (*opened_filename, FOPEN_RBIN);
+ f = gzopen (*opened_filename, FOPEN_RBIN);
}
if (!f)
{
free (*opened_filename);
*opened_filename = concat (filename, ".inz", "");
- f = fopen (*opened_filename, FOPEN_RBIN);
+ f = gzopen (*opened_filename, FOPEN_RBIN);
}
#endif /* __MSDOS__ */
if (!f)
@@ -754,7 +755,7 @@ open_possibly_compressed_file (char *fil
(*create_callback) (filename);
/* And try opening it again. */
- f = fopen (*opened_filename, FOPEN_RBIN);
+ f = gzopen (*opened_filename, FOPEN_RBIN);
if (!f)
return 0;
}
@@ -764,26 +765,26 @@ open_possibly_compressed_file (char *fil
/* Read first few bytes of file rather than relying on the filename.
If the file is shorter than this it can't be usable anyway. */
- nread = fread (data, sizeof (data), 1, f);
- if (nread != 1)
+ nread = gzread (f, data, sizeof (data));
+ if (nread != sizeof (data))
{
- if (nread == 0)
+ if (nread >= 0)
{
/* Try to create the file if its empty. */
- if (feof (f) && create_callback)
+ if (gzeof (f) && create_callback)
{
- if (fclose (f) != 0)
+ if (gzclose (f) < 0)
return 0; /* unknown error closing file */
if (remove (filename) != 0)
return 0; /* unknown error deleting file */
(*create_callback) (filename);
- f = fopen (*opened_filename, FOPEN_RBIN);
+ f = gzopen (*opened_filename, FOPEN_RBIN);
if (!f)
return 0;
- nread = fread (data, sizeof (data), 1, f);
- if (nread == 0)
+ nread = gzread (f, data, sizeof (data));
+ if (nread <= 0)
return 0;
goto determine_file_type; /* success */
}
@@ -854,35 +855,40 @@ determine_file_type:
*compression_program = NULL;
/* Seek back over the magic bytes. */
- if (fseek (f, 0, 0) < 0)
+ if (gzseek (f, 0, SEEK_SET) == -1)
return 0;
if (*compression_program)
{ /* It's compressed, so open a pipe. */
+ FILE *p;
char *command = concat (*compression_program, " -d", "");
- if (fclose (f) < 0)
+ if (gzclose (f) < 0)
return 0;
- f = freopen (*opened_filename, FOPEN_RBIN, stdin);
- if (!f)
+ p = freopen (*opened_filename, FOPEN_RBIN, stdin);
+ if (!p)
return 0;
- f = popen (command, "r");
- if (!f)
+ p = popen (command, "r");
+ if (!p)
{
/* Used for error message in calling code. */
*opened_filename = command;
return 0;
}
+ else
+ *is_pipe = 1;
+ return p;
}
else
{
-#if O_BINARY
+#if 0 && O_BINARY
/* Since this is a text file, and we opened it in binary mode,
switch back to text mode. */
f = freopen (*opened_filename, "r", f);
if (! f)
return 0;
#endif
+ *is_pipe = 0;
}
return f;
@@ -901,7 +907,8 @@ readfile (char *filename, int *sizep,
void (*create_callback) (char *), char **opened_filename,
char **compression_program)
{
- FILE *f;
+ void *f;
+ int pipe_p;
int filled = 0;
int data_size = 8192;
char *data = xmalloc (data_size);
@@ -909,14 +916,20 @@ readfile (char *filename, int *sizep,
/* If they passed the space for the file name to return, use it. */
f = open_possibly_compressed_file (filename, create_callback,
opened_filename,
- compression_program);
+ compression_program,
+ &pipe_p);
if (!f)
return 0;
for (;;)
{
- int nread = fread (data + filled, 1, data_size - filled, f);
+ int nread;
+
+ if (pipe_p)
+ nread = fread (data + filled, 1, data_size - filled, f);
+ else
+ nread = gzread (f, data + filled, data_size - filled);
if (nread < 0)
return 0;
if (nread == 0)
@@ -935,8 +948,10 @@ readfile (char *filename, int *sizep,
/* We need to close the stream, since on some systems the pipe created
by popen is simulated by a temporary file which only gets removed
inside pclose. */
- if (f != stdin)
+ if (pipe_p)
pclose (f);
+ else
+ gzclose (f);
*sizep = filled;
return data;
diff -up texinfo-6.5.91/install-info/Makefile.in.orig texinfo-6.5.91/install-info/Makefile.in
--- texinfo-6.5.91/install-info/Makefile.in.orig 2019-01-14 09:32:31.729895052 +0100
+++ texinfo-6.5.91/install-info/Makefile.in 2019-01-14 09:32:52.574914503 +0100
@@ -218,7 +218,7 @@ am__installdirs = "$(DESTDIR)$(bindir)"
PROGRAMS = $(bin_PROGRAMS)
am_ginstall_info_OBJECTS = install-info.$(OBJEXT)
ginstall_info_OBJECTS = $(am_ginstall_info_OBJECTS)
-ginstall_info_LDADD = $(LDADD)
+ginstall_info_LDADD = $(LDADD) -lz
am__DEPENDENCIES_1 =
ginstall_info_DEPENDENCIES = $(top_builddir)/gnulib/lib/libgnu.a \
$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1)

@ -1,25 +0,0 @@
diff -up texinfo-6.5.92/install-info/tests/Makefile.in.orig texinfo-6.5.92/install-info/tests/Makefile.in
--- texinfo-6.5.92/install-info/tests/Makefile.in.orig 2019-02-01 16:16:49.000000000 +0100
+++ texinfo-6.5.92/install-info/tests/Makefile.in 2019-02-18 10:33:52.078877104 +0100
@@ -1229,8 +1229,8 @@ ii-0021-test ii-0022-test ii-0023-test i
ii-0026-test ii-0027-test ii-0028-test ii-0029-test ii-0030-test \
ii-0031-test ii-0032-test ii-0033-test ii-0034-test ii-0035-test \
ii-0036-test ii-0037-test ii-0038-test ii-0039-test ii-0040-test \
-ii-0041-test ii-0042-test ii-0043-test ii-0044-test ii-0045-test \
-ii-0046-test ii-0047-test ii-0048-test ii-0049-test ii-0050-test \
+ii-0042-test ii-0043-test ii-0044-test ii-0045-test \
+ii-0046-test ii-0047-test ii-0048-test ii-0049-test \
ii-0051-test ii-0052-test ii-0053-test ii-0054-test ii-0055-test \
ii-0056-test ii-0057-test
diff -up texinfo-6.5.92/tp/tests/Makefile.in.orig texinfo-6.5.92/tp/tests/Makefile.in
--- texinfo-6.5.92/tp/tests/Makefile.in.orig 2019-02-01 16:16:50.000000000 +0100
+++ texinfo-6.5.92/tp/tests/Makefile.in 2019-02-18 10:33:13.774827269 +0100
@@ -1374,7 +1374,6 @@ one_test_files_generated_list = \
test_scripts/layout_formatting_html32.sh \
test_scripts/layout_formatting_regions.sh \
test_scripts/layout_formatting_exotic.sh \
- test_scripts/layout_formatting_fr_icons.sh \
test_scripts/layout_formatting_chm.sh \
test_scripts/layout_formatting_nodes.sh \
test_scripts/layout_formatting.sh \

@ -1,44 +0,0 @@
diff -up texinfo-6.1/install-info/install-info.c.orig texinfo-6.1/install-info/install-info.c
--- texinfo-6.1/install-info/install-info.c.orig 2016-06-22 09:49:38.766013018 +0200
+++ texinfo-6.1/install-info/install-info.c 2016-06-22 14:11:58.673780736 +0200
@@ -973,18 +973,23 @@ output_dirfile (char *dirfile, int dir_n
int n_entries_added = 0;
int i;
FILE *output;
+ char *dirfile_tmp = NULL;
+
+ asprintf (&dirfile_tmp, "%s.tmp", dirfile);
+ if (!dirfile_tmp)
+ xalloc_die ();
if (compression_program)
{
- char *command = concat (compression_program, ">", dirfile);
+ char *command = concat (compression_program, ">", dirfile_tmp);
output = popen (command, "w");
}
else
- output = fopen (dirfile, "w");
+ output = fopen (dirfile_tmp, "w");
if (!output)
{
- perror (dirfile);
+ perror (dirfile_tmp);
exit (EXIT_FAILURE);
}
@@ -1095,6 +1100,13 @@ output_dirfile (char *dirfile, int dir_n
pclose (output);
else
fclose (output);
+
+ if (rename (dirfile_tmp, dirfile) < 0)
+ {
+ perror (dirfile_tmp);
+ exit (EXIT_FAILURE);
+ }
+ free (dirfile_tmp);
}
/* Read through the input LINES, to find the section names and the

@ -1,18 +1,7 @@
diff -up texinfo-6.5.91/contrib/fix-info-dir.p7 texinfo-6.5.91/contrib/fix-info-dir
--- texinfo-6.5.91/contrib/fix-info-dir.p7 2019-01-21 10:52:18.453973008 +0100
+++ texinfo-6.5.91/contrib/fix-info-dir 2019-01-21 10:52:18.456973012 +0100
@@ -28,7 +28,6 @@ if test -z "$LINENO"; then
fi
MENU_BEGIN='^\*\([ ]\)\{1,\}Menu:'
-MENU_ITEM='^\* ([^ ]).*:([ ])+\('
MENU_FILTER1='s/^\*\([ ]\)\{1,\}/* /'
MENU_FILTER2='s/\([ ]\)\{1,\}$//g'
diff -up texinfo-6.5.91/info/infomap.c.p7 texinfo-6.5.91/info/infomap.c
--- texinfo-6.5.91/info/infomap.c.p7 2019-01-13 12:43:10.000000000 +0100
+++ texinfo-6.5.91/info/infomap.c 2019-01-21 10:52:18.457973013 +0100
@@ -589,6 +589,7 @@ fetch_user_maps (char *init_file)
diff -up texinfo-7.0.92/info/infomap.c.orig texinfo-7.0.92/info/infomap.c
--- texinfo-7.0.92/info/infomap.c.orig 2023-09-14 13:19:30.417330487 +0200
+++ texinfo-7.0.92/info/infomap.c 2023-09-14 13:19:55.870353408 +0200
@@ -590,6 +590,7 @@ fetch_user_maps (char *init_file)
compile (inf, filename, &sup_info, &sup_ea);
free (filename);
@ -20,74 +9,9 @@ diff -up texinfo-6.5.91/info/infomap.c.p7 texinfo-6.5.91/info/infomap.c
return 1;
}
diff -up texinfo-6.5.91/info/makedoc.c.p7 texinfo-6.5.91/info/makedoc.c
--- texinfo-6.5.91/info/makedoc.c.p7 2019-01-13 12:43:10.000000000 +0100
+++ texinfo-6.5.91/info/makedoc.c 2019-01-21 10:52:18.457973013 +0100
@@ -425,7 +425,11 @@ process_one_file (char *filename, FILE *
offset++;
if (offset >= file_size)
- break;
+ {
+ free (func_name);
+ free (func);
+ break;
+ }
doc = xmalloc (1 + (offset - point));
strncpy (doc, buffer + point, offset - point);
diff -up texinfo-6.5.91/info/m-x.c.p7 texinfo-6.5.91/info/m-x.c
--- texinfo-6.5.91/info/m-x.c.p7 2019-01-13 12:43:10.000000000 +0100
+++ texinfo-6.5.91/info/m-x.c 2019-01-21 10:52:18.457973013 +0100
@@ -79,7 +79,10 @@ DECLARE_INFO_COMMAND (describe_command,
InfoCommand *cmd = named_function (line);
if (!cmd)
- return;
+ {
+ free (line);
+ return;
+ }
window_message_in_echo_area ("%s: %s.",
line, function_documentation (cmd));
diff -up texinfo-6.5.91/info/nodes.c.p7 texinfo-6.5.91/info/nodes.c
--- texinfo-6.5.91/info/nodes.c.p7 2019-01-13 12:43:10.000000000 +0100
+++ texinfo-6.5.91/info/nodes.c 2019-01-21 10:52:18.457973013 +0100
@@ -303,7 +303,10 @@ get_nodes_of_tags_table (FILE_BUFFER *fi
for (p = 0; nodedef[p] && nodedef[p] != INFO_TAGSEP; p++)
;
if (nodedef[p] != INFO_TAGSEP)
- continue;
+ {
+ free (entry);
+ continue;
+ }
entry->nodename = xmalloc (p + 1);
strncpy (entry->nodename, nodedef, p);
@@ -477,6 +480,7 @@ get_tags_of_indirect_tags_table (FILE_BU
}
file_buffer->subfiles = NULL;
free_file_buffer_tags (file_buffer);
+ free (subfiles);
return;
}
diff -up texinfo-6.5.91/info/session.c.p7 texinfo-6.5.91/info/session.c
--- texinfo-6.5.91/info/session.c.p7 2019-01-13 12:43:10.000000000 +0100
+++ texinfo-6.5.91/info/session.c 2019-01-21 10:52:18.458973014 +0100
@@ -3552,6 +3552,7 @@ DECLARE_INFO_COMMAND (info_goto_invocati
if (!line)
{
info_abort_key (window, 0);
+ free (default_program_name);
return;
}
if (*line)
diff -up texinfo-6.5.91/info/variables.c.p7 texinfo-6.5.91/info/variables.c
--- texinfo-6.5.91/info/variables.c.p7 2019-01-13 12:43:10.000000000 +0100
+++ texinfo-6.5.91/info/variables.c 2019-01-21 10:52:18.459973015 +0100
diff -up texinfo-7.0.92/info/variables.c.orig texinfo-7.0.92/info/variables.c
--- texinfo-7.0.92/info/variables.c.orig 2023-09-14 13:20:14.464370153 +0200
+++ texinfo-7.0.92/info/variables.c 2023-09-14 13:21:00.343411464 +0200
@@ -359,6 +359,7 @@ read_variable_name (char *prompt, WINDOW
{
char *line;
@ -107,62 +31,4 @@ diff -up texinfo-6.5.91/info/variables.c.p7 texinfo-6.5.91/info/variables.c
}
/* Make an array of REFERENCE which actually contains the names of the
diff -up texinfo-6.5.91/install-info/install-info.c.p7 texinfo-6.5.91/install-info/install-info.c
--- texinfo-6.5.91/install-info/install-info.c.p7 2019-01-21 10:52:18.447973002 +0100
+++ texinfo-6.5.91/install-info/install-info.c 2019-01-21 10:52:18.460973016 +0100
@@ -864,10 +864,16 @@ determine_file_type:
char *command = concat (*compression_program, " -d", "");
if (gzclose (f) < 0)
- return 0;
+ {
+ free (command);
+ return 0;
+ }
p = freopen (*opened_filename, FOPEN_RBIN, stdin);
if (!p)
- return 0;
+ {
+ free (command);
+ return 0;
+ }
p = popen (command, "r");
if (!p)
{
@@ -877,6 +883,7 @@ determine_file_type:
}
else
*is_pipe = 1;
+ free (command);
return p;
}
else
@@ -920,7 +927,10 @@ readfile (char *filename, int *sizep,
&pipe_p);
if (!f)
- return 0;
+ {
+ free (data);
+ return 0;
+ }
for (;;)
{
@@ -980,6 +990,7 @@ output_dirfile (char *dirfile, int dir_n
{
char *command = concat (compression_program, ">", dirfile_tmp);
output = popen (command, "w");
+ free (command);
}
else
output = fopen (dirfile_tmp, "w");
@@ -1721,6 +1732,8 @@ reformat_new_entries (struct spec_entry
format_entry (name, name_len, desc, desc_len, calign, align,
maxwidth, &entry->text, &entry->text_len);
+ free (desc);
+ free (name);
}
}
diff -up texinfo-7.0.92/install-info/install-info.c.orig texinfo-7.0.92/install-info/install-info.c

@ -1,53 +0,0 @@
diff -up texinfo-6.7/gnulib/lib/regex_internal.c.orig texinfo-6.7/gnulib/lib/regex_internal.c
--- texinfo-6.7/gnulib/lib/regex_internal.c.orig 2019-08-25 19:11:45.000000000 +0200
+++ texinfo-6.7/gnulib/lib/regex_internal.c 2022-02-09 09:51:41.084596377 +0100
@@ -1724,7 +1724,10 @@ create_cd_newstate (const re_dfa_t *dfa,
}
if (re_node_set_init_copy (newstate->entrance_nodes, nodes)
!= REG_NOERROR)
- return NULL;
+ {
+ free_state (newstate);
+ return NULL;
+ }
nctx_nodes = 0;
newstate->has_constraint = 1;
}
diff -up texinfo-6.7/info/session.c.orig texinfo-6.7/info/session.c
--- texinfo-6.7/info/session.c.orig 2022-02-09 09:51:30.952589716 +0100
+++ texinfo-6.7/info/session.c 2022-02-09 09:51:41.085596377 +0100
@@ -2897,7 +2897,10 @@ DECLARE_INFO_COMMAND (info_menu_sequence
node = info_follow_menus (dir_node, nodes, &error, 0);
info_set_node_of_window (window, node);
if (error)
- show_error_node (error);
+ {
+ show_error_node (error);
+ free (error);
+ }
}
free (nodes);
@@ -3668,8 +3671,9 @@ DECLARE_INFO_COMMAND (info_view_file, _(
else
info_set_node_of_window (window, node);
- free (line);
}
+
+ free (line);
}
/* **************************************************************** */
diff -up texinfo-6.7/util/texi2dvi.orig texinfo-6.7/util/texi2dvi
--- texinfo-6.7/util/texi2dvi.orig 2019-09-23 20:28:10.000000000 +0200
+++ texinfo-6.7/util/texi2dvi 2022-02-09 09:51:41.086596378 +0100
@@ -1697,7 +1697,7 @@ cleanup ()
input_file_name_decode ()
{
case $command_line_filename in
- *\\input{*}*)
+ *\\input\{*\}*)
# Let AUC-TeX error parser deal with line numbers.
line_error=false
command_line_filename=`\

@ -1,12 +0,0 @@
diff -up texinfo-6.7/tp/tests/run_parser_all.sh.orig texinfo-6.7/tp/tests/run_parser_all.sh
--- texinfo-6.7/tp/tests/run_parser_all.sh.orig 2019-08-25 19:11:47.000000000 +0200
+++ texinfo-6.7/tp/tests/run_parser_all.sh 2021-02-02 14:36:15.290152957 +0100
@@ -46,7 +46,7 @@ check_latex2html_and_tex4ht ()
if echo "$remaining" | grep '[-]init mediawiki.pm' >/dev/null; then
if test "$no_html2wiki" = 'yes' ; then
echo "S: (no html2wiki) $current"
- continue 2
+ return 2
fi
fi
fi

@ -1,8 +0,0 @@
-----BEGIN PGP SIGNATURE-----
iI8EABEIADcWIQTq9mmzHjHh3svRFRPdvFedqzf7qQUCXYpOxhkcZ2F2aW5zbWl0
aDAxMjNAZ21haWwuY29tAAoJEN28V52rN/upFfsA/ijrBDSblwgcANew2xreyJMk
2oicyeBfOWwiSbjlBNSsAP4+mM2vwqo2CAHqUd2CHGV0tz/FnU7SxPrOdJneUIc2
xQ==
=5SpL
-----END PGP SIGNATURE-----

@ -0,0 +1,150 @@
diff -up texinfo-7.1/info/filesys.c.orig texinfo-7.1/info/filesys.c
diff -up texinfo-7.1/info/infokey.c.orig texinfo-7.1/info/infokey.c
--- texinfo-7.1/info/infokey.c.orig 2023-08-14 20:53:20.000000000 +0200
+++ texinfo-7.1/info/infokey.c 2024-08-07 12:12:04.651748655 +0200
@@ -208,7 +208,7 @@ compile (FILE *fp, const char *filename,
char oval = 0;
char comment[10];
unsigned int clen = 0;
- int seq[20];
+ int seq[20] = { 0 };
unsigned int slen = 0;
char act[80];
unsigned int alen = 0;
diff -up texinfo-7.1/info/session.c.orig texinfo-7.1/info/session.c
--- texinfo-7.1/info/session.c.orig 2023-08-15 14:52:09.000000000 +0200
+++ texinfo-7.1/info/session.c 2024-08-08 13:14:28.320463664 +0200
@@ -2335,7 +2335,7 @@ info_menu_or_ref_item (WINDOW *window, i
if (defentry)
{
prompt = xmalloc (strlen (defentry->label)
- + strlen (_("Menu item (%s): ")));
+ + strlen (_("Menu item (%s): ")) + 1);
sprintf (prompt, _("Menu item (%s): "), defentry->label);
}
else
@@ -2346,7 +2346,7 @@ info_menu_or_ref_item (WINDOW *window, i
if (defentry)
{
prompt = xmalloc (strlen (defentry->label)
- + strlen (_("Follow xref (%s): ")));
+ + strlen (_("Follow xref (%s): ")) + 1);
sprintf (prompt, _("Follow xref (%s): "), defentry->label);
}
else
@@ -2923,7 +2923,7 @@ DECLARE_INFO_COMMAND (info_menu_sequence
static int
info_handle_pointer (char *label, WINDOW *window)
{
- char *description;
+ char *description = NULL;
NODE *node;
if (!strcmp (label, "Up"))
@@ -3480,7 +3480,7 @@ info_intuit_options_node (NODE *node, ch
{
char *nodename;
- nodename = xmalloc (strlen (program) + strlen (*try_node));
+ nodename = xmalloc (strlen (program) + strlen (*try_node) + 1);
sprintf (nodename, *try_node, program);
/* The last resort "%s" is dangerous, so we restrict it
to exact matches here. */
@@ -3556,7 +3556,7 @@ DECLARE_INFO_COMMAND (info_goto_invocati
default_program_name = program_name_from_file_name (file_name);
prompt = xmalloc (strlen (default_program_name) +
- strlen (invocation_prompt));
+ strlen (invocation_prompt) + 1);
sprintf (prompt, invocation_prompt, default_program_name);
line = info_read_in_echo_area (prompt);
free (prompt);
diff -up texinfo-7.1/info/util.c.orig texinfo-7.1/info/util.c
--- texinfo-7.1/info/util.c.orig 2023-08-14 20:53:20.000000000 +0200
+++ texinfo-7.1/info/util.c 2024-08-07 12:12:04.656748661 +0200
@@ -34,9 +34,12 @@ xvasprintf (char **ptr, const char *temp
int
xasprintf (char **ptr, const char *template, ...)
{
+ int ret;
va_list v;
va_start (v, template);
- return xvasprintf (ptr, template, v);
+ ret = xvasprintf (ptr, template, v);
+ va_end (v);
+ return ret;
}
/* Return the file buffer which belongs to WINDOW's node. */
diff -up texinfo-7.1/install-info/install-info.c.orig texinfo-7.1/install-info/install-info.c
--- texinfo-7.1/install-info/install-info.c.orig 2023-10-08 17:57:24.000000000 +0200
+++ texinfo-7.1/install-info/install-info.c 2024-08-07 12:12:04.657748663 +0200
@@ -752,11 +752,15 @@ open_possibly_compressed_file (char *fil
return 0;
nread = fread (data, sizeof (data), 1, f);
if (nread == 0)
- return 0;
+ {
+ fclose (f);
+ return 0;
+ }
goto determine_file_type; /* success */
}
}
errno = 0;
+ fclose (f);
return 0; /* unknown error */
}
@@ -829,10 +833,16 @@ determine_file_type:
FILE *f2;
if (fclose (f) < 0)
- return 0;
+ {
+ free (command);
+ return 0;
+ }
f2 = freopen (*opened_filename, FOPEN_RBIN, stdin);
if (!f)
- return 0;
+ {
+ fclose (f2);
+ return 0;
+ }
f = popen (command, "r");
fclose (f2);
if (!f)
@@ -854,7 +864,10 @@ determine_file_type:
#else
/* Seek back over the magic bytes. */
if (fseek (f, 0, 0) < 0)
- return 0;
+ {
+ fclose (f);
+ return 0;
+ }
#endif
}
@@ -885,7 +898,10 @@ readfile (char *filename, int *sizep,
compression_program);
if (!f)
- return 0;
+ {
+ free (data);
+ return 0;
+ }
for (;;)
{
@@ -1836,7 +1852,7 @@ munge_old_style_debian_options (int argc
int *new_argc, char ***new_argv)
{
char *opt = NULL;
- int i, err;
+ int i, err = 0;
char *argz = NULL;
size_t argz_len = 0;
const char *regex, *title;

@ -0,0 +1,8 @@
-----BEGIN PGP SIGNATURE-----
iI8EABEIADcWIQTq9mmzHjHh3svRFRPdvFedqzf7qQUCZS/iphkcZ2F2aW5zbWl0
aDAxMjNAZ21haWwuY29tAAoJEN28V52rN/up5LYBALwlhLMF0ms2VhWq8mXvHbii
L2ySgaLsL1Pe3bFv6UC5AP0XSWsH5VQGq3wRVvo5KCH9TIi2aAMZ3RrfJbaPmxHS
xA==
=bAky
-----END PGP SIGNATURE-----

@ -2,34 +2,28 @@
Summary: Tools needed to create Texinfo format documentation files
Name: texinfo
Version: 6.7
Release: 15%{?dist}
License: GPLv3+
Version: 7.1
Release: 4%{?dist}
License: GPL-3.0-or-later
Url: http://www.gnu.org/software/texinfo/
Source0: ftp://ftp.gnu.org/gnu/texinfo/texinfo-%{version}.tar.xz
Source1: ftp://ftp.gnu.org/gnu/texinfo/texinfo-%{version}.tar.xz.sig
Patch0: texinfo-4.12-zlib.patch
# Patch1: this is needed just for koji/mock, all tests pass fine in local build
Patch1: texinfo-6.0-disable-failing-info-test.patch
# Patch2: rhbz#1348671, because of OSTree
Patch2: texinfo-6.1-install-info-use-create-tmp-then-rename-pattern.patch
# Patch3: we need to fix template fix-info-dir generates
Patch3: info-6.5-sync-fix-info-dir.patch
# Patch4: rhbz#1592433, bug in fix-info-dir --delete
Patch4: texinfo-6.5-fix-info-dir.patch
# Patch5: fixes issues detected by static analysis
Patch5: texinfo-6.5-covscan-fixes.patch
# Patch6: fixes issue found by ShellCheck in test script
Patch6: texinfo-6.7-fix-function-exit.patch
# Patch7: fixes another batch of issues detected by static analysis
Patch7: texinfo-6.7-convscan-fixes.patch
Source2: fix-info-dir
# Patch0: we need to fix template fix-info-dir generates
Patch0: info-6.5-sync-fix-info-dir.patch
# Patch1: rhbz#1592433, bug in fix-info-dir --delete
Patch1: texinfo-6.5-fix-info-dir.patch
# Patch2: fixes issues detected by static analysis
Patch2: texinfo-6.5-covscan-fixes.patch
# Patch3: fixes various issues found by static analysis
Patch3: texinfo-7.1-various-sast-fixes.patch
BuildRequires: make
BuildRequires: gcc
BuildRequires: perl-generators
BuildRequires: zlib-devel, ncurses-devel, help2man, perl(Data::Dumper)
BuildRequires: ncurses-devel, help2man, perl(Data::Dumper)
BuildRequires: perl(Locale::Messages), perl(Unicode::EastAsianWidth), perl(Text::Unidecode)
BuildRequires: perl(Storable), perl(Unicode::Normalize)
BuildRequires: perl(Storable), perl(Unicode::Normalize), perl(File::Copy)
# Texinfo perl packages are not installed in default perl library dirs
%global __provides_exclude ^perl\\(.*Texinfo.*\\)$
@ -46,6 +40,7 @@ are going to write documentation for the GNU Project.
%package -n info
Summary: A stand-alone TTY-based reader for GNU texinfo documentation
Provides: /sbin/install-info
%description -n info
The GNU project uses the texinfo file format for much of its
@ -71,7 +66,10 @@ The texinfo-tex package provides tools to format Texinfo documents
for printing using TeX.
%prep
%autosetup -p1
%setup -q
mkdir contrib
install -Dpm0755 -t contrib %{SOURCE2}
%autopatch -p1
%build
%configure --with-external-Text-Unidecode \
@ -88,7 +86,8 @@ mkdir -p ${RPM_BUILD_ROOT}/sbin
mkdir -p $RPM_BUILD_ROOT%{tex_texinfo}
install -p -m644 doc/texinfo.tex doc/txi-??.tex $RPM_BUILD_ROOT%{tex_texinfo}
mv $RPM_BUILD_ROOT%{_bindir}/install-info $RPM_BUILD_ROOT/sbin
mkdir -p $RPM_BUILD_ROOT%{_sbindir}
mv $RPM_BUILD_ROOT%{_bindir}/install-info $RPM_BUILD_ROOT%{_sbindir}
install -Dpm0755 -t %{buildroot}%{_sbindir} contrib/fix-info-dir
@ -120,6 +119,8 @@ export ALL_TESTS=yes
%{_bindir}/pod2texi
%{_datadir}/texinfo
%{_infodir}/texinfo*
%{_infodir}/texi2any_api.info*
%{_infodir}/texi2any_internals.info*
%{_mandir}/man1/makeinfo.1*
%{_mandir}/man5/texinfo.5*
%{_mandir}/man1/texi2any.1*
@ -129,7 +130,7 @@ export ALL_TESTS=yes
%license COPYING
%{_bindir}/info
%{_infodir}/info-stnd.info*
/sbin/install-info
%{_sbindir}/install-info
%{_sbindir}/fix-info-dir
%{_mandir}/man1/info.1*
%{_mandir}/man1/install-info.1*
@ -149,24 +150,66 @@ export ALL_TESTS=yes
%{_mandir}/man1/pdftexi2dvi.1*
%changelog
* Mon Feb 21 2022 Vitezslav Crhonek <vcrhonek@redhat.com> - 6.7-15
- Rebuild
Related: #1938884
* Thu Aug 08 2024 Vitezslav Crhonek <vcrhonek@redhat.com> - 7.1-4
- Fix memory/resource leaks, insufficient memory allocations and
variable declarations without initializer
Resolves: RHEL-43595
* Wed Feb 16 2022 Vitezslav Crhonek <vcrhonek@redhat.com> - 6.7-14
- Rebuild
Related: #1938884
* Mon Jun 24 2024 Troy Dawson <tdawson@redhat.com> - 7.1-3
- Bump release for June 2024 mass rebuild
* Sat Jan 27 2024 Fedora Release Engineering <releng@fedoraproject.org> - 7.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Tue Oct 24 2023 Vitezslav Crhonek <vcrhonek@redhat.com> - 7.1-1
- Update to texinfo-7.1
Resolves: #2244846
* Sat Jul 22 2023 Fedora Release Engineering <releng@fedoraproject.org> - 7.0.3-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Wed May 31 2023 Vitezslav Crhonek <vcrhonek@redhat.com> - 7.0.3-2
- SPDX migration
* Thu Mar 30 2023 Vitezslav Crhonek <vcrhonek@redhat.com> - 7.0.3-1
- Update to texinfo-7.0.3
Resolves: #2181837
* Wed Feb 22 2023 Vitezslav Crhonek <vcrhonek@redhat.com> - 7.0.2-2
- Fix possible use of an undefined value as an ARRAY reference in ParserNonXS.pm
(causes FTBFS of a2ps)
Resolves: #2171433
* Mon Jan 23 2023 Vitezslav Crhonek <vcrhonek@redhat.com> - 7.0.2-1
- Update to texinfo-7.0.2
Resolves: #2162979
* Sat Jan 21 2023 Fedora Release Engineering <releng@fedoraproject.org> - 7.0.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Thu Dec 01 2022 Vitezslav Crhonek <vcrhonek@redhat.com> - 7.0.1-1
- Update to texinfo-7.0.1
Resolves: #2149772
* Fri Nov 18 2022 Vitezslav Crhonek <vcrhonek@redhat.com> - 7.0-1
- Update to texinfo-7.0
Resolves: #2140872
* Sat Jul 23 2022 Fedora Release Engineering <releng@fedoraproject.org> - 6.8-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Sat Jan 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 6.8-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Thu Feb 10 2022 Vitezslav Crhonek <vcrhonek@redhat.com> - 6.7-13
- Fix issues found by static analysis
Resolves: #1938884
* Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 6.8-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
* Tue Aug 10 2021 Mohan Boddu <mboddu@redhat.com> - 6.7-12
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
Related: rhbz#1991688
* Tue Jul 20 2021 Vitezslav Crhonek <vcrhonek@redhat.com> - 6.8-1
- Update to texinfo-6.8
Resolves: #1978903
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 6.7-11
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
* Mon Jun 14 2021 Vitezslav Crhonek <vcrhonek@redhat.com> - 6.7-11
- Fix install path of install-info
* Tue Feb 02 2021 Vitezslav Crhonek <vcrhonek@redhat.com> - 6.7-10
- Fix problem in shell code found by ShellCheck in test script

Loading…
Cancel
Save