From owner-freebsd-current@FreeBSD.ORG Sat Sep 26 22:14:45 2009 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 637701065670; Sat, 26 Sep 2009 22:14:45 +0000 (UTC) (envelope-from sgk@troutmask.apl.washington.edu) Received: from troutmask.apl.washington.edu (troutmask.apl.washington.edu [128.208.78.105]) by mx1.freebsd.org (Postfix) with ESMTP id 4A3BE8FC14; Sat, 26 Sep 2009 22:14:45 +0000 (UTC) Received: from troutmask.apl.washington.edu (localhost.apl.washington.edu [127.0.0.1]) by troutmask.apl.washington.edu (8.14.3/8.14.3) with ESMTP id n8QMEjlV055721; Sat, 26 Sep 2009 15:14:45 -0700 (PDT) (envelope-from sgk@troutmask.apl.washington.edu) Received: (from sgk@localhost) by troutmask.apl.washington.edu (8.14.3/8.14.3/Submit) id n8QMEihW055720; Sat, 26 Sep 2009 15:14:44 -0700 (PDT) (envelope-from sgk) Date: Sat, 26 Sep 2009 15:14:44 -0700 From: Steve Kargl To: Jilles Tjoelker Message-ID: <20090926221444.GA55696@troutmask.apl.washington.edu> References: <20090926185128.GA53658@troutmask.apl.washington.edu> <20090926213130.GA88702@stack.nl> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20090926213130.GA88702@stack.nl> User-Agent: Mutt/1.4.2.3i Cc: gavin@freebsd.org, freebsd-current@freebsd.org, brian@freebsd.org Subject: Re: Revision 196634 of sh(1) breaks lp(1) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Sep 2009 22:14:45 -0000 On Sat, Sep 26, 2009 at 11:31:30PM +0200, Jilles Tjoelker wrote: > On Sat, Sep 26, 2009 at 11:51:28AM -0700, Steve Kargl wrote: > > troutmask:sgk[208] cat .cshrc | lp -d pug > > /usr/bin/lpr: cannot access > > > troutmask:sgk[209] uname -a > > FreeBSD troutmask.apl.washington.edu 9.0-CURRENT FreeBSD 9.0-CURRENT #0 r197195M: > > Mon Sep 14 11:11:46 PDT 2009 > > kargl@troutmask.apl.washington.edu:/usr/obj/usr/src/sys/SPEW amd64 > > The problem seems not because of r196634 of sh(1), but because of > r194171 of lp(1) (see also PR standards/129554). As of that revision, > lp passes an empty filename to lpr if the new -t option is not used. > lpr cannot access that file and prints the error message. > > The attached patch should fix the issue, and should also avoid invalid > arguments to lpr if an empty title is given. > > I use CUPS and not FreeBSD lpr so I just checked that the lpr command > looks right in sh -x. > The patch appears to works. Thanks. Sorry about pointing at the recent sh(1) changes. -- Steve