Module Name:    src
Committed By:   riz
Date:           Mon May  7 17:02:08 UTC 2012

Modified Files:
        src/usr.sbin/makemandb [netbsd-6]: makemandb.c

Log Message:
Pull up following revision(s) (requested by wiz in ticket #228):
        usr.sbin/makemandb/makemandb.c: revision 1.8
The new apropos(1) incorrectly displays hyphens in the first line
of the search results for a few man pages (for man(7) based man
pages).
Use patch from Abhinav Upadhyay in PR 46408 to fix this.


To generate a diff of this commit:
cvs rdiff -u -r1.2.2.3 -r1.2.2.4 src/usr.sbin/makemandb/makemandb.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/usr.sbin/makemandb/makemandb.c
diff -u src/usr.sbin/makemandb/makemandb.c:1.2.2.3 src/usr.sbin/makemandb/makemandb.c:1.2.2.4
--- src/usr.sbin/makemandb/makemandb.c:1.2.2.3	Mon Mar  5 19:16:27 2012
+++ src/usr.sbin/makemandb/makemandb.c	Mon May  7 17:02:07 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: makemandb.c,v 1.2.2.3 2012/03/05 19:16:27 sborrill Exp $	*/
+/*	$NetBSD: makemandb.c,v 1.2.2.4 2012/05/07 17:02:07 riz Exp $	*/
 /*
  * Copyright (c) 2011 Abhinav Upadhyay <er.abhinav.upadh...@gmail.com>
  * Copyright (c) 2011 Kristaps Dzonsons <krist...@bsd.lv>
@@ -17,7 +17,7 @@
  */
 
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: makemandb.c,v 1.2.2.3 2012/03/05 19:16:27 sborrill Exp $");
+__RCSID("$NetBSD: makemandb.c,v 1.2.2.4 2012/05/07 17:02:07 riz Exp $");
 
 #include <sys/stat.h>
 #include <sys/types.h>
@@ -1269,8 +1269,8 @@ pman_sh(const struct man_node *n, mandb_
 		 */
 		int has_alias = 0;	// Any more aliases left?
 		while (*name_desc) {
-			/* Remove any leading spaces. */
-			if (name_desc[0] == ' ') {
+			/* Remove any leading spaces or hyphens. */
+			if (name_desc[0] == ' ' || name_desc[0] =='-') {
 				name_desc++;
 				continue;
 			}

Reply via email to