From owner-freebsd-doc Mon Feb 26 23: 0: 9 2001 Delivered-To: freebsd-doc@freebsd.org Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 1FBD037B70D for ; Mon, 26 Feb 2001 23:00:02 -0800 (PST) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.11.1/8.11.1) id f1R702069055; Mon, 26 Feb 2001 23:00:02 -0800 (PST) (envelope-from gnats) Received: from cfcl.com (cpe-24-221-169-54.ca.sprintbbd.net [24.221.169.54]) by hub.freebsd.org (Postfix) with ESMTP id 1465137B70A for ; Mon, 26 Feb 2001 22:51:42 -0800 (PST) (envelope-from rdm@cfcl.com) Received: (from rdm@localhost) by cfcl.com (8.9.3/8.9.3) id WAA21848; Mon, 26 Feb 2001 22:51:09 -0800 (PST) (envelope-from rdm) Message-Id: <200102270651.WAA21848@cfcl.com> Date: Mon, 26 Feb 2001 22:51:09 -0800 (PST) From: Rich Morin Reply-To: rdm@cfcl.com To: FreeBSD-gnats-submit@freebsd.org X-Send-Pr-Version: 3.2 Subject: docs/25405: misleading warning from catman(1), etc. Sender: owner-freebsd-doc@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 25405 >Category: docs >Synopsis: misleading warning from catman(1), etc. >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-doc >State: open >Quarter: >Keywords: >Date-Required: >Class: doc-bug >Submitter-Id: current-users >Arrival-Date: Mon Feb 26 23:00:01 PST 2001 >Closed-Date: >Last-Modified: >Originator: Rich Morin >Release: FreeBSD 4.2-RELEASE i386 >Organization: Canta Forda Computer Laboratory >Environment: FreeBSD fb42.cfcl.com 4.2-RELEASE FreeBSD 4.2-RELEASE #0: Mon Nov 20 13:02:55 GMT 2000 jkh@bento.FreeBSD.org:/usr/src/sys/compile/GENERIC i386 >Description: If catman(1) is run as root, the message: Don't start this program as root, use: echo /usr/bin/catman | nice -5 su -m man appears. There are really several problems here: 1) The program should check whether catman is actually being run by root before issuing the warning. 2) If an error has occurred, the program should exit, rather then going on to write root-owned files in /usr/share/man/cat* (or wherever...). 3) The program should be clever enough to _do_ the necessary work, rather than telling the user how to do it. Basically, the programmer has gratuitously broken the method of operation for a command. 4) The programmer's instructions to the user make use of an undocumented feature of man(1). What, exactly, is going on when we pipe this text string into man? In passing, I will note that the warning messages emitted by this command string: Unknown FreeBSD version ``),'' at line 320 Unknown BSD version ``'' at line 5 Unknown BSD version ``'' at line 5 are essentially useless, as the user has no way of knowing which man page is being discussed. >How-To-Repeat: % su # catman >Fix: Recode catman, as described above. >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-doc" in the body of the message