1 |
– |
/* Copyright (c) 1992 Regents of the University of California */ |
2 |
– |
|
1 |
|
#ifndef lint |
2 |
< |
static char SCCSid[] = "$SunId$ LBL"; |
2 |
> |
static const char RCSid[] = "$Id$"; |
3 |
|
#endif |
6 |
– |
|
4 |
|
/* |
5 |
|
* oki20c.c - program to dump pixel file to OkiMate 20 color printer. |
6 |
|
*/ |
7 |
|
|
8 |
|
#include <stdio.h> |
9 |
< |
#ifdef MSDOS |
13 |
< |
#include <fcntl.h> |
14 |
< |
#endif |
9 |
> |
#include <time.h> |
10 |
|
|
11 |
+ |
#include "platform.h" |
12 |
|
#include "color.h" |
13 |
|
#include "resolu.h" |
14 |
|
|
37 |
|
char *argv[]; |
38 |
|
{ |
39 |
|
int i, status = 0; |
40 |
< |
#ifdef MSDOS |
41 |
< |
extern int _fmode; |
42 |
< |
_fmode = O_BINARY; |
47 |
< |
setmode(fileno(stdin), O_BINARY); |
48 |
< |
setmode(fileno(stdout), O_BINARY); |
49 |
< |
#endif |
40 |
> |
SET_DEFAULT_BINARY(); |
41 |
> |
SET_FILE_BINARY(stdin); |
42 |
> |
SET_FILE_BINARY(stdout); |
43 |
|
if (argc > 1 && !strcmp(argv[1], "-p")) { |
44 |
|
dofilter++; |
45 |
|
argv++; argc--; |
46 |
|
} |
54 |
– |
#ifdef _IOLBF |
55 |
– |
stdout->_flag &= ~_IOLBF; |
56 |
– |
#endif |
47 |
|
if (argc < 2) |
48 |
|
status = printp(NULL) == -1; |
49 |
|
else |