I am running LPRng 3.7.4 and would like to use a perl script as a
replacement filter for ifhp. The problem I am encountering is lpd is
generating an error even when the script exits successfully. I developed
a test filter as a diagnostic tool which does nothing except for read
from STDIN and writes to STDOUT. I searched the list archives and my perl
script appears to be using the correct syntax. Has anyone encountered
this problem before.
Status: waiting for subserver to exit at 16:03:09.558
Status: subserver pid 24224 starting at 16:03:09.699
Status: accounting at start at 16:03:09.699
Status: opening device '/dev/null' at 16:03:09.725
Status: printing job 'fausey@localhost+222' at 16:03:09.727
Status: creating banner at 16:03:09.728
Status: Filter_file: pgm '/var/local/LPRng/libexec/filters/cit.banner.sh' exited with
status 'JSUCC' at 16:03:10.606
Status: processing 'dfA222localhost.princeton.edu', size 61, format 'f', IF filter
'test-filter.pl' at 16:03:10.609
Status: IF filter 'test-filter.pl' filter finished at 16:03:11.488
Status: printing finished at 16:03:11.489
Status: test: Get_status_from_OF: LP, of_error 5 closed! - Bad file number at
16:03:11.489
Status: subserver pid 24224 exit status 'JABORT' at 16:03:11.555
Status: job 'cfA222localhost.princeton.edu' error 'aborting operations' at
16:03:11.556
Status: sending mail to '[EMAIL PROTECTED]' at 16:03:11.578
Status: removing job 'cfA222tatooine.princeton.edu' - ABORT at 16:03:12.391
printcap:
test
:lp=/dev/null
:sd=/var/local/LPRng/spool/lpd/%P
:lf=/var/local/LPRng/spool/lpd/%P/log
:bp=/var/local/LPRng/libexec/filters/cit.banner.sh
:if=/var/local/LPRng/libexec/filters/test-filter.pl
:filter=/var/local/LPRng/libexec/filters/ifhp
:ab:ml=0:mx#0:mc=0:rw:bk
test-filter.pl:
#!/usr/bin/perl
use Getopt::Std;
getopt( 'efPHnJCLADQNF0wxy' );
open( FILE, "$opt_e" ) or die "Sorry could not open spool file $opt_e: $!\n";
while( <FILE> ) {
print $_;
}
close( FILE );
#exit;
Rob Fausey.
-----------------------------------------------------------------------------
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
The address you post from MUST be your subscription address
If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body. For the impatient,
to subscribe to a list with name LIST, send mail to [EMAIL PROTECTED]
with: | example:
subscribe LIST <mailaddr> | subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST <mailaddr> | unsubscribe lprng [EMAIL PROTECTED]
If you have major problems, send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-----------------------------------------------------------------------------