--- ray/src/px/oki20c.c 2003/02/22 02:07:27 2.11 +++ ray/src/px/oki20c.c 2003/10/27 10:24:51 2.14 @@ -1,16 +1,15 @@ #ifndef lint -static const char RCSid[] = "$Id: oki20c.c,v 2.11 2003/02/22 02:07:27 greg Exp $"; +static const char RCSid[] = "$Id: oki20c.c,v 2.14 2003/10/27 10:24:51 schorsch Exp $"; #endif /* * oki20c.c - program to dump pixel file to OkiMate 20 color printer. */ #include -#ifdef MSDOS -#include -#endif #include +#include "platform.h" +#include "rtprocess.h" #include "color.h" #include "resolu.h" @@ -31,20 +30,15 @@ long lpat[NCOLS][3]; int dofilter = 0; /* filter through pfilt first? */ -extern FILE *popen(); - main(argc, argv) int argc; char *argv[]; { int i, status = 0; -#ifdef MSDOS - extern int _fmode; - _fmode = O_BINARY; - setmode(fileno(stdin), O_BINARY); - setmode(fileno(stdout), O_BINARY); -#endif + SET_DEFAULT_BINARY(); + SET_FILE_BINARY(stdin); + SET_FILE_BINARY(stdout); if (argc > 1 && !strcmp(argv[1], "-p")) { dofilter++; argv++; argc--; @@ -130,7 +124,7 @@ int y; register long c; register int i, j; - if (bpos = y % 23) { + if ( (bpos = y % 23) ) { for (j = 0; j < 3; j++) for (i = 0; i < len; i++)