[arch-commits] Commit in man-db/trunk (PKGBUILD fix-14467.patch)

Thomas Bächler thomas at archlinux.org
Sun Jun 21 09:47:00 UTC 2009


    Date: Sunday, June 21, 2009 @ 05:47:00
  Author: thomas
Revision: 43277

upgpkg: man-db 2.5.5-2

Added:
  man-db/trunk/fix-14467.patch
Modified:
  man-db/trunk/PKGBUILD

-----------------+
 PKGBUILD        |   12 +++++++++---
 fix-14467.patch |   46 ++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 55 insertions(+), 3 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2009-06-21 08:14:47 UTC (rev 43276)
+++ PKGBUILD	2009-06-21 09:47:00 UTC (rev 43277)
@@ -4,7 +4,7 @@
 
 pkgname=man-db
 pkgver=2.5.5
-pkgrel=1
+pkgrel=2
 pkgdesc="A utility for reading man pages"
 arch=('i686' 'x86_64')
 url="http://www.nongnu.org/man-db/"
@@ -20,11 +20,13 @@
 source=(#http://savannah.nongnu.org/download/man-db/$pkgname-$pkgver.tar.gz
 	http://launchpad.net/man-db/main/${pkgver}/+download/${pkgname}-${pkgver}.tar.gz
         convert-mans man-db.cron.daily
-	rev1051.diff)
+	rev1051.diff
+	fix-14467.patch)
 md5sums=('ca382dd934fc8b9e9a64d13354be48cf'
          '2b7662a7d5b33fe91f9f3e034361a2f6'
          'acdff891e224511cf26c92de77347db8'
-         '7dc2e8324cbc2ae777fe966ef7a7d0c8')
+         '7dc2e8324cbc2ae777fe966ef7a7d0c8'
+         '90554646622ffc1258648bd79a2f8e4c')
 
 build() {
   cd ${srcdir}/${pkgname}-${pkgver}
@@ -33,6 +35,10 @@
   # see http://bugs.archlinux.org/task/13734 and http://bugs.debian.org/519807 ; solved in 
   # http://bzr.savannah.gnu.org/lh/man-db/trunk/revision/1051?start_revid=1055&filter_file_id=x_Arch_Librarian_<arch%40canonical.com>_Tue_Mar_22_20%3A41%3A03_2005_29634.0
   patch -Np0 -i ${srcdir}/rev1051.diff || return 1
+  # libdb/db_lookup.c (dblookup): In exact mode, make sure extensions                                                                                                   
+  # match exactly, rather than merely that the extension found is a                                                                                                     
+  # prefix of that which was requested (http://bugs.archlinux.org/task/14467).      
+  patch -Np0 -i ${srcdir}/fix-14467.patch || return 1
   
   autoreconf -fv
   

Added: fix-14467.patch
===================================================================
--- fix-14467.patch	                        (rev 0)
+++ fix-14467.patch	2009-06-21 09:47:00 UTC (rev 43277)
@@ -0,0 +1,46 @@
+=== modified file 'libdb/db_lookup.c'
+--- libdb/db_lookup.c	2008-12-25 22:13:50 +0000
++++ libdb/db_lookup.c	2009-06-21 01:29:52 +0000
+@@ -323,11 +323,15 @@
+ 		if (!info->name)
+ 			info->name = xstrdup (page);
+ 		if (!(flags & MATCH_CASE) || STREQ (info->name, page)) {
+-			if (section == NULL ||
+-			    STRNEQ (section, info->ext,
+-				    flags & EXACT ? strlen (info->ext) :
+-						    strlen (section))) {
++			if (section == NULL)
+ 				return info;
++			if (flags & EXACT) {
++				if (STREQ (section, info->ext))
++					return info;
++			} else {
++				if (STRNEQ (section, info->ext,
++					    strlen (section)))
++					return info;
+ 			}
+ 		}
+ 		free_mandata_struct (info);
+@@ -357,11 +361,16 @@
+ 			if ((flags & MATCH_CASE) && !STREQ (names[i], page))
+ 				continue;
+ 
+-			if (section != NULL &&
+-			    !STRNEQ (section, ext[i],
+-				     flags & EXACT ? strlen (ext[i])
+-						   : strlen (section)))
+-				continue;
++			if (section != NULL) {
++				if (flags & EXACT) {
++					if (!STREQ (section, ext[i]))
++						continue;
++				} else {
++					if (!STRNEQ (section, ext[i],
++						     strlen (section)))
++						continue;
++				}
++			}
+ 
+ 			/* So the key is suitable ... */
+ 			key = make_multi_key (names[i], ext[i]);
+




More information about the arch-commits mailing list