[14579] in Athena Bugs

home help back first fref pref prev next nref lref last post

sun4 8.0I: lpr -h -h

daemon@ATHENA.MIT.EDU (Jacob Morzinski)
Wed Aug 21 15:04:58 1996

To: bugs@MIT.EDU
Date: Wed, 21 Aug 1996 15:04:54 EDT
From: "Jacob Morzinski" <jmorzins@MIT.EDU>

System name:		w20-575-45
Type and version:	SPARC/4 8.0I
Display type:		cgthree

What were you trying to do?
	Print a file at the printer, without a header page.

What's wrong:
	lpr's -h acts as a toggle, which makes life really confusing
	for users who have aliased 'ls' to 'ls -h', or who have set
	the LPROPT variable to '-h'.  This could be construed as
	a bug.

What should have happened:
	-h ought be -h, regardless of whether it has been used in
	the optionlist already.  A more sane syntax to turn off an
	existing '-h' switch might be the use of '+h'.

Please describe any relevant documentation references:

  echo "hi" > /tmp/foo
  lpr /tmp/foo ; lpr -h /tmp/foo ; lpr -h -h /tmp/foo
  lpr -h -h -h /tmp/foo ; lpr -h -h -h -h /tmp/foo

...these lines produce output which alternate between printing a
header page and not printing a header page.  (Whether or not the
first invocation produces a header page depends on the value of the
LPROPT variable.)

home help back first fref pref prev next nref lref last post