[man-db] * Resolves: #684977 backport upstream patch

Ivana Varekova varekova at fedoraproject.org
Wed Mar 23 13:05:41 UTC 2011


commit f73d977692ec3b332be648df734061d25593aaef
Author: Ivana Hutarova Varekova <varekova at redhat.com>
Date:   Wed Mar 23 15:16:15 2011 +0100

    * Resolves: #684977
      backport upstream patch

 man-db-2.5.9-sec.patch |   25 +++++++++++++++++++++++++
 man-db.spec            |    8 +++++++-
 2 files changed, 32 insertions(+), 1 deletions(-)
---
diff --git a/man-db-2.5.9-sec.patch b/man-db-2.5.9-sec.patch
new file mode 100644
index 0000000..a103e33
--- /dev/null
+++ b/man-db-2.5.9-sec.patch
@@ -0,0 +1,25 @@
+diff -up man-db-2.5.9/src/man.c.pom man-db-2.5.9/src/man.c
+--- man-db-2.5.9/src/man.c.pom	2010-11-17 12:31:24.000000000 +0100
++++ man-db-2.5.9/src/man.c	2011-03-23 12:11:46.000000000 +0100
+@@ -2827,6 +2827,21 @@ static int compare_candidates (const str
+ 	 * moved out of order with respect to their parent sections.
+ 	 */
+ 	if (strcmp (lsource->ext, rsource->ext)) {
++		const char **sp;
++
++		/* If the user asked for an explicit section, sort exact
++		 * matches first.
++		 */
++		if (section) {
++			if (STREQ (lsource->ext, section)) {
++				if (!STREQ (rsource->ext, section))
++					return -1;
++			} else {
++				if (STREQ (rsource->ext, section))
++					return 1;
++			}
++		}
++
+ 		/* Find out whether lsource->ext is ahead of rsource->ext in
+ 		 * section_list.
+ 		 */
diff --git a/man-db.spec b/man-db.spec
index 787f37f..4468574 100644
--- a/man-db.spec
+++ b/man-db.spec
@@ -3,7 +3,7 @@
 Summary: Tools for searching and reading man pages
 Name: man-db
 Version: 2.5.9
-Release: 4%{?dist}
+Release: 5%{?dist}
 # project man-db  GPLv2+
 # Gnulib part     GPLv3+
 License: GPLv2+ and GPLv3+
@@ -15,6 +15,7 @@ Source2: man-db.sysconfig
 Patch0: man-db-2.5.9-config.patch
 # Resolves: #655385 - use old format of nroff output
 Patch1: man-db-2.5.9-sgr.patch
+Patch2: man-db-2.5.9-sec.patch
 Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 Obsoletes: man < 2.0
 Provides: man-pages-reader = %{version}
@@ -35,6 +36,7 @@ manual pages.
 %setup -q
 %patch0 -p1 -b .conf
 %patch1 -p1 -b .sgr
+%patch2 -p1 -b .sec
 
 %build
 %configure\
@@ -116,6 +118,10 @@ rm -rf $RPM_BUILD_ROOT
 %lang(ja)   %{_datadir}/man/ja/man*/*
 
 %changelog
+* Wed Mar 23 2011 Ivana Hutarova Varekova <varekova at redhat.com> - 2.5.9-5
+* Resolves: #684977
+  backport upstream patch
+
 * Tue Feb 08 2011 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 2.5.9-4
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
 


More information about the scm-commits mailing list