lpr.c:
2,3 c 2,5
<  * Submit a listing to the local line
<  * printer spooler.
---
>  * lpr.c
>  * 12/13/90
>  * Submit a listing to the line printer spooler.
>  * This source produces both lpr and (compiled -DLASER) hpr.
9 d 10
< #ifndef	TYPES_H
11 d 11
< #endif
12 a 13,18
> #ifdef	LASER
> #define	USAGE	"Usage: %s [-Bcemnr] [-b banner] [-f fontnum] [file ...]\n"
> #else
> #define	USAGE	"Usage: %s [-Bcmnr] [-b banner] [file ...]\n"
> #endif
> 
26 c 32
< #ifdef LASER
---
> #ifdef	LASER
33 c 39
< char	tmb[] = "Too many banners, `%s' ignored";
---
> char	tmb[] = "too many banners, '%s' ignored";
40 a 47,51
> #ifdef	LASER
> int	eflag;		/* Erase existing fonts */
> int	fflag;		/* Load new fonts */
> int	fontindex;	/* Current font index */
> #endif
42 c 53,58
< long	unique();
---
> extern	char	*ctime();
> extern	char	*getenv();
> extern	char	*getlogin();
> extern	char	*getwd();
> extern	time_t	time();
> 
44,46 c 60,61
< char	*getwd();
< char	*ctime();
< char	*getlogin();
---
> void	lpr();
> void	lprinit();
47 a 63
> long	unique();
49,50 c 65
< main(argc, argv)
< char *argv[];
---
> main(argc, argv) int argc; char *argv[];
69 c 84
< 					lperr("Missing banner");
---
> 					lperr("missing banner");
79 a 95,107
> #ifdef	LASER
> 			case 'e':
> 				eflag = 1;
> 				break;
> 
> 			case 'f':
> 				Bflag = fflag = 1;	/* -f forces -B */
> 				if (++i >= argc)
> 					lperr("missing font index");
> 				else
> 					fontindex = atoi(argv[i]);
> 				break;
> #endif
96 a 125,128
> #ifdef	LASER
> 	if (eflag)
> 		fprintf(cfp, "E\n");
> #endif
99 c 131
< 	for (j=i; j<argc; j++)
---
> 	for (j = i; j < argc; j++)
104 c 136
< 	for (j=0; j<banno; j++)
---
> 	for (j = 0; j < banno; j++)
116 c 148
< 	lperr("Cannot find daemon `%s'", lpd);
---
> 	lperr("cannot find daemon '%s'", lpd);
123,124 c 155,156
< lprinit(ac, av)
< char **av;
---
> void
> lprinit(ac, av) int ac; char **av;
126 c 158
< 	time_t time(), xtime;
---
> 	time_t xtime;
134 c 166
< 		lperr("bad directory `%s'", spooldir);
---
> 		lperr("bad directory '%s'", spooldir);
163 c 195
<  * The NULL `file' is stdin.
---
>  * The NULL 'file' is stdin.
165,166 c 197,198
< lpr(file)
< char *file;
---
> void
> lpr(file) char *file;
180 c 212,218
< 		fprintf(cfp, "A%s\nU%s\n", dfname, dfname);
---
> #ifdef	LASER
> 		if (fflag)
> 			fprintf(cfp, "F%s %d\n", dfname, fontindex++);
> 		else
> #endif
> 			fprintf(cfp, "A%s\n", dfname);
> 		fprintf(cfp, "U%s\n", dfname);
182,183 c 220,227
< 	} else
< 		fprintf(cfp, "A%s\n", abfile);
---
> 	} else {
> #ifdef	LASER
> 		if (fflag)
> 			fprintf(cfp, "F%s %d\n", abfile, fontindex++);
> 		else
> #endif
> 			fprintf(cfp, "A%s\n", abfile);
> 	}
186 c 230
< 			lperr("Cannot unlink %s", file);
---
> 			lperr("cannot unlink %s", file);
226 c 270
< 		lperr("Control file I/O error");
---
> 		lperr("control file I/O error");
257 c 301
<  * (Uses the variable `wd' which
---
>  * (Uses the variable 'wd' which
275 c 319
< 	fprintf(stderr, "Usage: %s [-Bcmnr] [-b banner] [file ...]\n", argv0);
---
> 	fprintf(stderr, USAGE, argv0);
297 a 342,343
> 
> /* end of lpr.c */

