From owner-freebsd-stable@FreeBSD.ORG Mon Jul 16 05:13:36 2012 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 9C9C1106566B for ; Mon, 16 Jul 2012 05:13:36 +0000 (UTC) (envelope-from Devin.Teske@fisglobal.com) Received: from mx1.fisglobal.com (mx1.fisglobal.com [199.200.24.190]) by mx1.freebsd.org (Postfix) with ESMTP id 620E88FC0A for ; Mon, 16 Jul 2012 05:13:35 +0000 (UTC) Received: from smtp.fisglobal.com ([10.132.206.16]) by ltcfislmsgpa05.fnfis.com (8.14.4/8.14.4) with ESMTP id q6G5DWKb019629 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NOT); Mon, 16 Jul 2012 00:13:32 -0500 Received: from LTCFISWMSGMB21.FNFIS.com ([10.132.99.23]) by LTCFISWMSGHT05.FNFIS.com ([10.132.206.16]) with mapi id 14.02.0309.002; Mon, 16 Jul 2012 00:13:32 -0500 From: "Teske, Devin" To: Thomas Mueller Thread-Topic: less and vi fail on file whose name begins with + Thread-Index: AQHNYxG+kns/Nop77Uad5qAvIz0z9A== Date: Mon, 16 Jul 2012 05:13:16 +0000 Message-ID: <13CA24D6AB415D428143D44749F57D7201D7B060@ltcfiswmsgmb21> References: In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.14.152.61] Content-Type: text/plain; charset="us-ascii" Content-ID: <840A6575BA2F494886A8E611603835C1@fisglobal.com> Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:5.7.7855, 1.0.260, 0.0.0000 definitions=2012-07-16_01:2012-07-16, 2012-07-16, 1970-01-01 signatures=0 Cc: "" Subject: Re: less and vi fail on file whose name begins with + X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Jul 2012 05:13:36 -0000 On Jul 15, 2012, at 10:03 PM, Thomas Mueller wrot= e: > I notice in my latest build of FreeBSD 9.0-STABLE (#11), a problem with l= ess and vi with files whose name begins with +. >=20 > These files occur in /var/db/pkg/(pkg-name)/ >=20 > For instance, if I cd /var/db/pkg/png-1.4.8 > and type=20 > less +DESC=20 > I get >=20 > Missing filename ("less --help" for help) >=20 > but if I type the filename with full path, or even=20 > less ./+DESC=20 > it works OK >=20 > I also tried going to /tmp and > echo abcdefg > +junk1.txt > and the same bug with less showed up (no problem with echo). >=20 > I tried vi instead of less, not really wanting to edit the file, > and vi tried to open a temporary file on /tmp with a strange name. >=20 > Has anybody noticed this bug? It affects i386 and amd64 at least. >=20 > I have no access to test on other architectures. >=20 > If this bug is found, we no doubt want it to be squashed before 9.1-RELEA= SE. >=20 Neither of these are "bugs" and I assure you they are as old as the hills (= maybe not vi but always vim -- did you recently alias vi to vim?) For less, try this: less +/wheel < /etc/group The + precedes an initial command. Similar with vi[m]. Simple way 'round is to use "--", e.g. below: vi -- +DESC --=20 Devin _____________ The information contained in this message is proprietary and/or confidentia= l. If you are not the intended recipient, please: (i) delete the message an= d all copies; (ii) do not disclose, distribute or use the message in any ma= nner; and (iii) notify the sender immediately. In addition, please be aware= that any message addressed to our domain is subject to archiving and revie= w by persons other than the intended recipient. Thank you.