mirror of
https://git.freebsd.org/src.git
synced 2026-01-16 23:02:24 +00:00
This commit was manufactured to restore the state of the 1.1.5.1-RELEASE image. Releases prior to 5.3-RELEASE are omitting the secure/ and crypto/ subdirs.
38 lines
830 B
C
38 lines
830 B
C
/*
|
|
source to my hp filter, installed as /usr/libexec/lpr/hpf:
|
|
*/
|
|
#include "stdio.h"
|
|
#include <signal.h>
|
|
#include <sys/file.h>
|
|
#include <sys/ioctl.h>
|
|
#include <sgtty.h>
|
|
|
|
main(ac, av)
|
|
int ac;
|
|
char **av;
|
|
{
|
|
int c;
|
|
struct sgttyb nbuf;
|
|
unsigned long lbits;
|
|
|
|
setbuf(stdout, NULL);
|
|
lbits = LDECCTQ | LPASS8 | LLITOUT;
|
|
ioctl(fileno(stdout), TIOCLSET, &lbits);
|
|
ioctl(fileno(stdout), TIOCGETP, &nbuf);
|
|
nbuf.sg_flags &= ~(ECHO | XTABS | CRMOD);
|
|
ioctl(fileno(stdout), TIOCSETP, &nbuf);
|
|
|
|
fputs("\033E\033&k2G", stdout);
|
|
|
|
while (1) {
|
|
if ((c = getchar()) != EOF) {
|
|
putchar(c);
|
|
} else {
|
|
break;
|
|
}
|
|
}
|
|
|
|
fputs("\033&l0H", stdout);
|
|
|
|
exit(0);
|
|
}
|