From owner-cvs-all@FreeBSD.ORG Thu Sep 29 20:40:30 2005 Return-Path: X-Original-To: cvs-all@FreeBSD.org Delivered-To: cvs-all@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B075E16A420; Thu, 29 Sep 2005 20:40:30 +0000 (GMT) (envelope-from dougb@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5620643D55; Thu, 29 Sep 2005 20:40:30 +0000 (GMT) (envelope-from dougb@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j8TKeT42068157; Thu, 29 Sep 2005 20:40:30 GMT (envelope-from dougb@repoman.freebsd.org) Received: (from dougb@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j8TKeTPf068156; Thu, 29 Sep 2005 20:40:29 GMT (envelope-from dougb) Message-Id: <200509292040.j8TKeTPf068156@repoman.freebsd.org> From: Doug Barton Date: Thu, 29 Sep 2005 20:40:29 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Cc: Subject: cvs commit: src/bin/rm rm.1 rm.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 29 Sep 2005 20:40:30 -0000 dougb 2005-09-29 20:40:29 UTC FreeBSD src repository Modified files: bin/rm rm.1 rm.c Log: Handle the case where the -P flag is specified for a read-only file earlier, and more gracefully. Previously, this combination would be ignored early in the code where permissions are tested and fail later with a very unhelpful "permission denied" error. Instead, test for this flag in the same block that generates the "override?" messages for read-only files, but instead of trying to guess what the user has in mind, generate an error and exit. Update the man page to reflect this new behavior. Not objected to by: freebsd-hackers@ Revision Changes Path 1.37 +4 -0 src/bin/rm/rm.1 1.53 +5 -4 src/bin/rm/rm.c