Subject: bin/12742: catman complains about invalid directories when using explicit MANPATH
To: None <gnats-bugs@gnats.netbsd.org>
From: Brian de Alwis <bsd@fifty.cs.ubc.ca>
List: netbsd-bugs
Date: 04/24/2001 14:54:06
>Number:         12742
>Category:       bin
>Synopsis:       catman complains about invalid directories when using explicit MANPATH
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    bin-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Apr 24 14:54:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator:     Brian de Alwis
>Release:        NetBSD 1.5
>Organization:
>Environment:
System: NetBSD fifty 1.5 NetBSD 1.5 (GENERIC) #1: Sun Nov 19 21:42:11 MET 2000 fvdl@sushi:/work/trees/netbsd-1-5/sys/arch/i386/compile/GENERIC i386


>Description:
	I tried using catman(1)'s `-w' to rebuild various whatis.db's,
	explicitly specified with `-M'.  catman complains vociferously
	about invalid directories. This is with the shipped /etc/man.conf.

	I have an explicitly specified MANPATH. Unsetting it does
	not help.

>How-To-Repeat:

    Here's an example session:

    fifty:/usr/stuff/home/bsd[1](1)$ echo $MANPATH
    /usr/local/man:/usr/share/man:/usr/X11R6/man:/usr/pkg/man:/data/software/man
    fifty:/usr/stuff/home/bsd[2](1)$ catman -w -M /usr/share/man
    catman: can't open /usr/share/man/man1{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man8{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man6{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man2{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man3{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man4{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man5{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man7{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man3f{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man9{/i386,}: No such file or directory
    catman: can't open /usr/share/man/mann{/i386,}: No such file or directory
    catman: can't open /usr/share/man/manl{/i386,}: No such file or directory
    fifty:/usr/stuff/home/bsd[3](1)$ unset MANPATH
    fifty:/usr/stuff/home/bsd[4](1)$ catman -w -M /usr/share/man
    catman: can't open /usr/share/man/man1{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man8{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man6{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man2{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man3{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man4{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man5{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man7{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man3f{/i386,}: No such file or directory
    catman: can't open /usr/share/man/man9{/i386,}: No such file or directory
    catman: can't open /usr/share/man/mann{/i386,}: No such file or directory
    catman: can't open /usr/share/man/manl{/i386,}: No such file or directory
    fifty:/usr/stuff/home/bsd[5](1)$ 

>Fix:
	I briefly looked through the code, but it was rather tortuous
	(I don't get the settings of f_nowhatis and dowhatis and
	really couldn't be bothered once I found I could explicitly
	use /usr/libexec/makewhatis)
>Release-Note:
>Audit-Trail:
>Unformatted: