From owner-freebsd-questions Wed Jun 12 01:16:51 1996 Return-Path: owner-questions Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id BAA07417 for questions-outgoing; Wed, 12 Jun 1996 01:16:51 -0700 (PDT) Received: from mail.rwth-aachen.de (mail.RWTH-Aachen.DE [137.226.144.9]) by freefall.freebsd.org (8.7.5/8.7.3) with ESMTP id BAA07403 for ; Wed, 12 Jun 1996 01:16:44 -0700 (PDT) Received: from gilberto.physik.rwth-aachen.de (gilberto.physik.rwth-aachen.de) by mail.rwth-aachen.de (PMDF V5.0-4 #13110) id <01I5TESHH680001WM5@mail.rwth-aachen.de>; Wed, 12 Jun 1996 09:37:17 +0100 Received: (from kuku@localhost) by gilberto.physik.rwth-aachen.de (8.6.11/8.6.9) id JAA04245; Wed, 12 Jun 1996 09:45:50 +0200 Date: Wed, 12 Jun 1996 09:45:50 +0200 (MET DST) From: "Christoph P. Kukulies" Subject: Re: ghostscript In-reply-to: <31BE3BAA.41C67EA6@ptd.net> To: nickf@ptd.net (NickHead) Cc: questions@freebsd.org Reply-to: Christoph Kukulies Message-id: <199606120745.JAA04245@gilberto.physik.rwth-aachen.de> MIME-version: 1.0 X-Mailer: ELM [version 2.4ME+ PL16 (25)] Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7bit Sender: owner-questions@freebsd.org X-Loop: FreeBSD.org Precedence: bulk > I'm having a problem with ghostscript 3.51...hopefully someone can help! > > When I print from netscape (the only PS application I use) I get an > extra page at the end of the document that looks like this: > > Operand stack: > Execution stack: > %interp_exit () --nostr > > > I'm using an HP LaserJet 4+ printer here is my /etc/printcap: > > # @(#)printcap 5.3 (Berkeley) 6/30/90 > > lp|local line printer:\ > :sh:lp=/dev/lpt0:sd=/var/spool/output/lpd:lf=/var/log/lpd-errs:\ > :if=/usr/local/libexec/hplj: > > and my filter: > > #!/bin/sh > # > printf "\033&k2G" || exit 2 > # > read first_line > first_two_chars=`expr "$first_line" : '\(..\)'` > # > if [ "$first_two_chars" = "%!" ]; then > /usr/local/bin/gs -dSAFER -dNOPAUSE -q -sDEVICE=ljet4 I assume you don't have a tru line break at the end of the previous line. I would insert a tee >/tmp/teelog | in front of the /usr/local/bin/gs line to see what is actually fed into gs. > -sOutputFile=- - \ && exit 0 > else > echo $first_line && cat && printf "\f" && exit 2 > fi > exit 2 > > If anyone can help, please e-mail at nickf@ptd.net > > Thanx! Nick > --Chris Christoph P. U. Kukulies kuku@gil.physik.rwth-aachen.de