diff --git a/0005-Fix-possible-out-of-buffer-write.patch b/0005-Fix-possible-out-of-buffer-write.patch new file mode 100644 index 0000000000000000000000000000000000000000..e0d868e32c92d01cfb5c8b254973c0f618294652 --- /dev/null +++ b/0005-Fix-possible-out-of-buffer-write.patch @@ -0,0 +1,28 @@ +From df3b9600a16061a7661a58ba2750228b07825486 Mon Sep 17 00:00:00 2001 +From: "bas@zoetekouw.net" +Date: Wed, 9 Aug 2017 12:22:24 +0200 +Subject: [PATCH] Fix possible out-of-buffer write + +--- + src/manual.c | 5 ++--- + 1 file changed, 2 insertions(+), 3 deletions(-) + +diff --git a/src/manual.c b/src/manual.c +index 09b77f7..431dd66 100644 +--- a/src/manual.c ++++ b/src/manual.c +@@ -211,9 +211,8 @@ construct_manualname(char *buf, int which) + ptr++; + strcpy(buf, ptr); + tmppos = strlen(buf); +- /* TODO: check the following statement */ +- if (tmppos > 1); +- buf[tmppos - 2] = 0; ++ if (tmppos > 1) ++ buf[tmppos - 2] = 0; + strcat(buf, manuallinks[which].name); + xfree(base); + } +-- +2.33.0 + diff --git a/pinfo.spec b/pinfo.spec index c67d1d74571034b4fad9297014140965c43dab39..813fed3e9a2433524142eb41e58621eb90d59855 100644 --- a/pinfo.spec +++ b/pinfo.spec @@ -1,6 +1,6 @@ Name: pinfo Version: 0.6.10 -Release: 28 +Release: 29 Summary: An user-friendly, console-based viewer for Info documents License: GPLv2 URL: http://pinfo.alioth.debian.org @@ -16,6 +16,7 @@ Patch0008: 0001-Gracefully-handle-missing-indirect-info-nodes.patch Patch0009: 0002-Fix-infinite-loop-when-regexp-matching-an-empty-stri.patch Patch0010: 0003-Fix-segfautl-by-closing-unopened-file.patch Patch0011: 0004-Fix-link-order-in-ncurses-autoconf-test.patch +Patch0012: 0005-Fix-possible-out-of-buffer-write.patch BuildRequires: ncurses-devel automake gettext-devel libtool texinfo Requires: xdg-utils @@ -56,6 +57,9 @@ Pinfo-help provides man pages and other related help documents for pinfo. %{_mandir}/man1/pinfo.1* %changelog +* Tue Dec 12 2023 liyuanyuan - 0.6.10-29 +- Fix possible out-of-buffer write + * Fri Nov 24 2023 liyuanyuan - 0.6.10-28 - Fix link order in ncurses autoconf test