1 |
< |
/* Copyright (c) 1986 Regents of the University of California */ |
1 |
> |
/* Copyright (c) 1992 Regents of the University of California */ |
2 |
|
|
3 |
|
#ifndef lint |
4 |
|
static char SCCSid[] = "$SunId$ LBL"; |
12 |
|
|
13 |
|
#include <stdio.h> |
14 |
|
|
15 |
+ |
#ifdef MSDOS |
16 |
+ |
#include <fcntl.h> |
17 |
+ |
#endif |
18 |
+ |
|
19 |
|
extern int fputs(); |
20 |
|
|
21 |
|
|
43 |
|
argc--; argv++; |
44 |
|
dim = 1; |
45 |
|
} else if (argc == 2 && !strcmp(argv[1], "-")) { |
46 |
+ |
#ifdef MSDOS |
47 |
+ |
setmode(fileno(stdin), O_BINARY); |
48 |
+ |
setmode(fileno(stdout), O_BINARY); |
49 |
+ |
#endif |
50 |
|
getheader(stdin, NULL); |
51 |
|
copycat(); |
52 |
|
exit(0); |
116 |
|
copycat() /* copy input to output */ |
117 |
|
{ |
118 |
|
register int c; |
119 |
< |
|
119 |
> |
|
120 |
|
while ((c = getchar()) != EOF) |
121 |
|
putchar(c); |
122 |
|
} |