From owner-freebsd-questions@FreeBSD.ORG Tue Jan 15 00:16:21 2013 Return-Path: Delivered-To: questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 81F0E16E for ; Tue, 15 Jan 2013 00:16:21 +0000 (UTC) (envelope-from fbsd8@a1poweruser.com) Received: from mail-03.name-services.com (mail-03.name-services.com [69.64.155.195]) by mx1.freebsd.org (Postfix) with ESMTP id 46B86722 for ; Tue, 15 Jan 2013 00:16:21 +0000 (UTC) Received: from [10.0.10.3] ([173.88.197.103]) by mail-03.name-services.com with Microsoft SMTPSVC(6.0.3790.4675); Mon, 14 Jan 2013 16:16:22 -0800 Message-ID: <50F49FD2.10400@a1poweruser.com> Date: Mon, 14 Jan 2013 19:16:18 -0500 From: Fbsd8 User-Agent: Thunderbird 2.0.0.17 (Windows/20080914) MIME-Version: 1.0 To: Lowell Gilbert Subject: Re: sh script problem with capturing return code References: <50EC9009.3030305@a1poweruser.com> <20130108224626.8c2d89cd.freebsd@edvax.de> <50EC99F2.3020404@a1poweruser.com> <44d2xevlhb.fsf@lowell-desk.lan> <50ED88CF.7060308@a1poweruser.com> <448v82unxb.fsf@lowell-desk.lan> <444niqum7n.fsf@lowell-desk.lan> <44zk0it6t5.fsf@lowell-desk.lan> <44r4ltu8zp.fsf@lowell-desk.lan> <50EE2604.4020809@a1poweruser.com> <44pq188tnx.fsf@lowell-desk.lan> <50F41797.2050001@a1poweruser.com> <44y5fvg2o0.fsf@lowell-desk.lan> In-Reply-To: <44y5fvg2o0.fsf@lowell-desk.lan> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 15 Jan 2013 00:16:22.0225 (UTC) FILETIME=[8C682410:01CDF2B5] X-Sender: fbsd8@a1poweruser.com X-Authenticated-Sender: fbsd8@a1poweruser.com X-EchoSenderHash: [fbsd8]-[a1poweruser*com] Cc: FreeBSD questions X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 15 Jan 2013 00:16:21 -0000 Lowell Gilbert wrote: > Fbsd8 writes: > >> Lowell Gilbert wrote: > >>> This fixes the problem that was bothering you, but the interactions of >>> different features are complicated, and many of them are documented in >>> fairly loose language. >>> >> Is that the diplomatic way of saying the manpage for mtree sucks, and >> leaves a great deal to be desired? > > Not really; I was looking at the code at the time I wrote that. To be > fair, I'm not sure what I would *expect* for some of the possible > interactions. > >> When it comes to testing your patch sure I would like to. But here >> again I have a problem. For security reasons I can not use source code >> to install or update any operating system. I have no sources on my >> system to compile from. I use the fresh install method from a >> downloaded disc1.iso burned to cdrom. > > I was thinking you could extend the shell scripts using your existing > mtree executable. > Well I have already played with all the mtree(8) options you are interested in -u, -U, -q, -d, and different combinations of them including the specification keywords of "nochange", and "ignore", and in all cases the return code is always zero even when the test case should result in a return code of 1 or 2. I had no requirements to use the "optional" keyword, but after the 15+ combinations I ran I see no reason to expect the "optional", keyword to change the results I got.