8 |
|
#include <signal.h> |
9 |
|
#include <ctype.h> |
10 |
|
|
11 |
< |
#include "rtprocess.h" /* win_popen() */ |
11 |
> |
#include "paths.h" /* win_popen() */ |
12 |
|
#include "mkillum.h" |
13 |
|
|
14 |
|
/* default parameters */ |
45 |
|
int warnings = 1; /* print warnings? */ |
46 |
|
|
47 |
|
void init(char *octnm, int np); |
48 |
< |
void filter(register FILE *infp, char *name); |
48 |
> |
void filter(FILE *infp, char *name); |
49 |
|
void xoptions(char *s, char *nm); |
50 |
|
void printopts(void); |
51 |
< |
void printhead(register int ac, register char **av); |
51 |
> |
void printhead(int ac, char **av); |
52 |
|
void xobject(FILE *fp, char *nm); |
53 |
|
|
54 |
|
|
61 |
|
int nprocs = 1; |
62 |
|
FILE *fp; |
63 |
|
int rval; |
64 |
< |
register int i; |
64 |
> |
int i; |
65 |
|
/* set global arguments */ |
66 |
|
gargv = argv; |
67 |
|
progname = gargv[0]; |
148 |
|
|
149 |
|
void |
150 |
|
eputs( /* put string to stderr */ |
151 |
< |
register char *s |
151 |
> |
char *s |
152 |
|
) |
153 |
|
{ |
154 |
|
static int midline = 0; |
177 |
|
int ec; |
178 |
|
{ |
179 |
|
if (ray_pnprocs > 0) /* close children if any */ |
180 |
< |
ray_pclose(0); |
180 |
> |
ray_pclose(0); |
181 |
> |
else if (ray_pnprocs < 0) |
182 |
> |
_exit(ec); /* avoid flush() in child */ |
183 |
|
exit(ec); |
184 |
|
} |
185 |
|
|
186 |
|
|
187 |
|
void |
188 |
|
filter( /* process stream */ |
189 |
< |
register FILE *infp, |
189 |
> |
FILE *infp, |
190 |
|
char *name |
191 |
|
) |
192 |
|
{ |
193 |
|
char buf[512]; |
194 |
|
FILE *pfp; |
195 |
< |
register int c; |
195 |
> |
int c; |
196 |
|
|
197 |
|
while ((c = getc(infp)) != EOF) { |
198 |
|
if (isspace(c)) |
224 |
|
char *nm |
225 |
|
) |
226 |
|
{ |
225 |
– |
extern FILE *freopen(); |
227 |
|
char buf[64]; |
228 |
|
int negax; |
229 |
|
int nerrs = 0; |
230 |
< |
register char *cp; |
230 |
> |
char *cp; |
231 |
|
|
232 |
|
if (strncmp(s, "#@mkillum", 9) || !isspace(s[9])) { |
233 |
|
fputs(s, stdout); /* not for us */ |
410 |
|
|
411 |
|
void |
412 |
|
printhead( /* print out header */ |
413 |
< |
register int ac, |
414 |
< |
register char **av |
413 |
> |
int ac, |
414 |
> |
char **av |
415 |
|
) |
416 |
|
{ |
417 |
|
putchar('#'); |