Update to 2.7.0.2

- resolves: #1145493
This commit is contained in:
Jan Chaloupka 2014-10-08 13:03:43 +02:00
parent cc7d744d46
commit 52a4b8a1c9
5 changed files with 10 additions and 3690 deletions

2
.gitignore vendored
View File

@ -1 +1 @@
/man-db-2.6.7.1.tar.xz
/man-db-2.7.0.2.tar.xz

View File

@ -1,66 +0,0 @@
From 6748c88ed5ec74ec08226b46eb16eabf0d138a0d Mon Sep 17 00:00:00 2001
From: Jan Chaloupka <jchaloup@redhat.com>
Date: Wed, 17 Sep 2014 16:03:23 +0200
Subject: [PATCH] Don't store canonicalised versions of manpath elements
---
src/manp.c | 20 ++++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)
diff --git a/src/manp.c b/src/manp.c
index 4501721..75e43f2 100644
--- a/src/manp.c
+++ b/src/manp.c
@@ -1219,7 +1219,7 @@ void create_pathlist (const char *manp, char **mp)
/* Eliminate duplicates due to symlinks. */
mp = mphead;
while (*mp) {
- char *target, *oldmp = NULL;
+ char *target;
char **dupcheck;
int found_dup = 0;
@@ -1227,20 +1227,25 @@ void create_pathlist (const char *manp, char **mp)
* manpath?
*/
target = canonicalize_file_name (*mp);
- if (target) {
- oldmp = *mp;
- *mp = target;
+ if (!target) {
+ ++mp;
+ continue;
}
/* Only check up to the current list position, to keep item
* order stable across deduplication.
*/
for (dupcheck = mphead; *dupcheck && dupcheck != mp;
++dupcheck) {
- if (!STREQ (*mp, *dupcheck))
+ char *dupcheck_target = canonicalize_file_name
+ (*dupcheck);
+ if (!STREQ (target, dupcheck_target)) {
+ free (dupcheck_target);
continue;
+ }
+ free (dupcheck_target);
debug ("Removing duplicate manpath entry %s (%td) -> "
"%s (%td)\n",
- oldmp, mp - mphead,
+ *mp, mp - mphead,
*dupcheck, dupcheck - mphead);
free (*mp);
for (dupcheck = mp; *(dupcheck + 1); ++dupcheck)
@@ -1249,8 +1254,7 @@ void create_pathlist (const char *manp, char **mp)
found_dup = 1;
break;
}
- if (oldmp)
- free (oldmp);
+ free (target);
if (!found_dup)
++mp;
}
--
1.9.3

View File

@ -3,8 +3,8 @@
Summary: Tools for searching and reading man pages
Name: man-db
Version: 2.6.7.1
Release: 7%{?dist}
Version: 2.7.0.2
Release: 1%{?dist}
# GPLv2+ .. man-db
# GPLv3+ .. gnulib
License: GPLv2+ and GPLv3+
@ -15,9 +15,6 @@ Source0: http://download.savannah.gnu.org/releases/%{name}/%{name}-%{version}.ta
Source1: man-db.crondaily
Source2: man-db.sysconfig
Patch0: 1110274-Add-systemd-tmpfiles-snippet-to-clean-up-old-cat-fil.patch
Patch1: 1043401-Don-t-store-canonicalised-versions-of-manpath-elemen.patch
Obsoletes: man < 2.0
Provides: man = %{version}
Provides: man-pages-reader = %{version}
@ -38,8 +35,6 @@ manual pages.
%prep
%setup -q
%patch0 -p1
%patch1 -p1
%build
%configure \
@ -58,7 +53,8 @@ make install DESTDIR=$RPM_BUILD_ROOT prefix=%{_prefix} INSTALL='install -p'
mv $RPM_BUILD_ROOT%{_datadir}/doc/man-db/* ./
# remove zsoelim - part of groff package
rm $RPM_BUILD_ROOT%{_bindir}/zsoelim
#rm $RPM_BUILD_ROOT%{_bindir}/zsoelim
rm $RPM_BUILD_ROOT%{_libexecdir}/%{name}/zsoelim
rm $RPM_BUILD_ROOT%{_datadir}/man/man1/zsoelim.1
# remove libtool archives
@ -129,6 +125,10 @@ install -D -p -m 0644 init/systemd/man-db.conf $RPM_BUILD_ROOT/usr/lib/tmpfiles.
%lang(zh_CN) %{_datadir}/man/zh_CN/man*/*
%changelog
* Wed Oct 08 2014 jchaloup <jchaloup@redhat.com> - 2.7.0.2-1
- Update to 2.7.0.2
resolves: #1145493
* Thu Sep 18 2014 jchaloup <jchaloup@redhat.com> - 2.6.7.1-7
- resolves: #1043401
Don't store canonicalised versions of manpath elements

View File

@ -1 +1 @@
ce7b697f8e8016a085d9f5975ae6c4fb man-db-2.6.7.1.tar.xz
8ea7be9daf7af7da0fcd619e3da3991c man-db-2.7.0.2.tar.xz