11 |
|
#include <time.h> |
12 |
|
|
13 |
|
#include "platform.h" |
14 |
+ |
#include "rtprocess.h" |
15 |
|
#include "view.h" |
16 |
|
#include "paths.h" |
17 |
|
#include "vars.h" |
22 |
|
#else |
23 |
|
#define DELCMD "rm -f" |
24 |
|
#define RENAMECMD "mv" |
25 |
+ |
#include <sys/types.h> |
26 |
+ |
#include <sys/wait.h> |
27 |
|
#endif |
28 |
|
|
29 |
|
/* variables (alphabetical by name) */ |
109 |
|
int touchonly = 0; /* touch files only */ |
110 |
|
int nprocs = 1; /* maximum executing processes */ |
111 |
|
int sayview = 0; /* print view out */ |
112 |
< |
char *rvdevice = NULL; /* rview output device */ |
112 |
> |
char *rvdevice = NULL; /* rvu output device */ |
113 |
|
char *viewselect = NULL; /* specific view only */ |
114 |
|
|
115 |
|
int overture = 0; /* overture calculation needed */ |
123 |
|
|
124 |
|
#define inchild() (children_running < 0) |
125 |
|
|
126 |
+ |
static void rootname(char *rn, char *fn); |
127 |
+ |
static time_t checklast(char *fnames); |
128 |
+ |
static char * newfname(char *orig, int pred); |
129 |
+ |
static void checkfiles(void); |
130 |
+ |
static void getoctcube(double org[3], double *sizp); |
131 |
+ |
static void setdefaults(void); |
132 |
+ |
static void oconv(void); |
133 |
+ |
static char * addarg(char *op, char *arg); |
134 |
+ |
static void oconvopts(char *oo); |
135 |
+ |
static void mkillumopts(char *mo); |
136 |
+ |
static void checkambfile(void); |
137 |
+ |
static double ambval(void); |
138 |
+ |
static void renderopts(char *op, char *po); |
139 |
+ |
static void lowqopts(char *op, char *po); |
140 |
+ |
static void medqopts(char *op, char *po); |
141 |
+ |
static void hiqopts(char *op, char *po); |
142 |
+ |
static void xferopts(char *ro); |
143 |
+ |
static void pfiltopts(char *po); |
144 |
+ |
static int matchword(char *s1, char *s2); |
145 |
+ |
static char * specview(char *vs); |
146 |
+ |
static char * getview(int n, char *vn); |
147 |
+ |
static int myprintview(char *vopts, FILE *fp); |
148 |
+ |
static void rvu(char *opts, char *po); |
149 |
+ |
static void rpict(char *opts, char *po); |
150 |
+ |
static int touch(char *fn); |
151 |
+ |
static int runcom(char *cs); |
152 |
+ |
static int rmfile(char *fn); |
153 |
+ |
static int mvfile(char *fold, char *fnew); |
154 |
+ |
static int next_process(void); |
155 |
+ |
static void wait_process(int all); |
156 |
+ |
static void finish_process(void); |
157 |
+ |
static void badvalue(int vc); |
158 |
+ |
static void syserr(char *s); |
159 |
|
|
160 |
< |
main(argc, argv) |
161 |
< |
int argc; |
162 |
< |
char *argv[]; |
160 |
> |
|
161 |
> |
int |
162 |
> |
main( |
163 |
> |
int argc, |
164 |
> |
char *argv[] |
165 |
> |
) |
166 |
|
{ |
167 |
|
char ropts[512]; |
168 |
|
char popts[64]; |
238 |
|
renderopts(ropts, popts); |
239 |
|
xferopts(ropts); |
240 |
|
if (rvdevice != NULL) |
241 |
< |
rview(ropts, popts); |
241 |
> |
rvu(ropts, popts); |
242 |
|
else |
243 |
|
rpict(ropts, popts); |
244 |
|
quit(0); |
247 |
|
"Usage: %s [-w][-s][-n|-N npr][-t][-e][-V][-v view][-o dev] rfile [VAR=value ..]\n", |
248 |
|
progname); |
249 |
|
quit(1); |
250 |
+ |
return 1; /* pro forma return */ |
251 |
|
} |
252 |
|
|
253 |
|
|
254 |
< |
rootname(rn, fn) /* remove tail from end of fn */ |
255 |
< |
register char *rn, *fn; |
254 |
> |
static void |
255 |
> |
rootname( /* remove tail from end of fn */ |
256 |
> |
register char *rn, |
257 |
> |
register char *fn |
258 |
> |
) |
259 |
|
{ |
260 |
|
char *tp, *dp; |
261 |
|
|
269 |
|
} |
270 |
|
|
271 |
|
|
272 |
< |
time_t |
273 |
< |
checklast(fnames) /* check files and find most recent */ |
274 |
< |
register char *fnames; |
272 |
> |
static time_t |
273 |
> |
checklast( /* check files and find most recent */ |
274 |
> |
register char *fnames |
275 |
> |
) |
276 |
|
{ |
277 |
|
char thisfile[PATH_MAX]; |
278 |
|
time_t thisdate, lastdate = 0; |
281 |
|
return(0); |
282 |
|
while ((fnames = nextword(thisfile, PATH_MAX, fnames)) != NULL) { |
283 |
|
if (thisfile[0] == '!' || |
284 |
< |
(thisfile[0] == '\\' && thisfile[1] == '!')) |
284 |
> |
(thisfile[0] == '\\' && thisfile[1] == '!')) { |
285 |
> |
if (!lastdate) |
286 |
> |
lastdate = 1; |
287 |
|
continue; |
288 |
+ |
} |
289 |
|
if (!(thisdate = fdate(thisfile))) |
290 |
|
syserr(thisfile); |
291 |
|
if (thisdate > lastdate) |
295 |
|
} |
296 |
|
|
297 |
|
|
298 |
< |
char * |
299 |
< |
newfname(orig, pred) /* create modified file name */ |
300 |
< |
char *orig; |
301 |
< |
int pred; |
298 |
> |
static char * |
299 |
> |
newfname( /* create modified file name */ |
300 |
> |
char *orig, |
301 |
> |
int pred |
302 |
> |
) |
303 |
|
{ |
304 |
|
register char *cp; |
305 |
|
register int n; |
321 |
|
} |
322 |
|
|
323 |
|
|
324 |
< |
checkfiles() /* check for existence and modified times */ |
324 |
> |
static void |
325 |
> |
checkfiles(void) /* check for existence and modified times */ |
326 |
|
{ |
327 |
|
time_t objdate; |
328 |
|
|
357 |
|
} |
358 |
|
|
359 |
|
|
360 |
< |
getoctcube(org, sizp) /* get octree bounding cube */ |
361 |
< |
double org[3], *sizp; |
360 |
> |
static void |
361 |
> |
getoctcube( /* get octree bounding cube */ |
362 |
> |
double org[3], |
363 |
> |
double *sizp |
364 |
> |
) |
365 |
|
{ |
314 |
– |
extern FILE *popen(); |
366 |
|
static double oorg[3], osiz = 0.; |
367 |
|
double min[3], max[3]; |
368 |
|
char buf[1024]; |
410 |
|
} |
411 |
|
|
412 |
|
|
413 |
< |
setdefaults() /* set default values for unassigned var's */ |
413 |
> |
static void |
414 |
> |
setdefaults(void) /* set default values for unassigned var's */ |
415 |
|
{ |
416 |
|
double org[3], lim[3], size; |
417 |
|
char buf[128]; |
468 |
|
} |
469 |
|
|
470 |
|
|
471 |
< |
oconv() /* run oconv and mkillum if necessary */ |
471 |
> |
static void |
472 |
> |
oconv(void) /* run oconv and mkillum if necessary */ |
473 |
|
{ |
474 |
|
static char illumtmp[] = "ilXXXXXX"; |
475 |
< |
char combuf[PATH_MAX], ocopts[64], mkopts[64]; |
475 |
> |
char combuf[PATH_MAX], ocopts[64], mkopts[1024]; |
476 |
|
|
477 |
|
oconvopts(ocopts); /* get options */ |
478 |
|
if (octreedate < scenedate) { /* check date on original octree */ |
571 |
|
} |
572 |
|
|
573 |
|
|
574 |
< |
char * |
575 |
< |
addarg(op, arg) /* add argument and advance pointer */ |
576 |
< |
register char *op, *arg; |
574 |
> |
static char * |
575 |
> |
addarg( /* add argument and advance pointer */ |
576 |
> |
register char *op, |
577 |
> |
register char *arg |
578 |
> |
) |
579 |
|
{ |
580 |
|
*op = ' '; |
581 |
|
while ( (*++op = *arg++) ) |
584 |
|
} |
585 |
|
|
586 |
|
|
587 |
< |
oconvopts(oo) /* get oconv options */ |
588 |
< |
register char *oo; |
587 |
> |
static void |
588 |
> |
oconvopts( /* get oconv options */ |
589 |
> |
register char *oo |
590 |
> |
) |
591 |
|
{ |
592 |
|
/* BEWARE: This may be called via setdefaults(), so no assumptions */ |
593 |
|
|
597 |
|
} |
598 |
|
|
599 |
|
|
600 |
< |
mkillumopts(mo) /* get mkillum options */ |
601 |
< |
register char *mo; |
600 |
> |
static void |
601 |
> |
mkillumopts( /* get mkillum options */ |
602 |
> |
char *mo |
603 |
> |
) |
604 |
|
{ |
605 |
|
/* BEWARE: This may be called via setdefaults(), so no assumptions */ |
606 |
|
|
607 |
< |
*mo = '\0'; |
607 |
> |
if (nprocs > 1) { |
608 |
> |
sprintf(mo, " -n %d", nprocs); |
609 |
> |
while (*mo) |
610 |
> |
mo++; |
611 |
> |
} else |
612 |
> |
*mo = '\0'; |
613 |
|
if (vdef(MKILLUM)) |
614 |
|
addarg(mo, vval(MKILLUM)); |
615 |
|
} |
616 |
|
|
617 |
|
|
618 |
< |
checkambfile() /* check date on ambient file */ |
618 |
> |
static void |
619 |
> |
checkambfile(void) /* check date on ambient file */ |
620 |
|
{ |
621 |
|
time_t afdate; |
622 |
|
|
633 |
|
} |
634 |
|
|
635 |
|
|
636 |
< |
double |
637 |
< |
ambval() /* compute ambient value */ |
636 |
> |
static double |
637 |
> |
ambval(void) /* compute ambient value */ |
638 |
|
{ |
639 |
|
if (vdef(EXPOSURE)) { |
640 |
|
if (vval(EXPOSURE)[0] == '+' || vval(EXPOSURE)[0] == '-') |
646 |
|
if (vlet(ZONE) == 'I') |
647 |
|
return(.01); |
648 |
|
badvalue(ZONE); |
649 |
+ |
return 0; /* pro forma return */ |
650 |
|
} |
651 |
|
|
652 |
|
|
653 |
< |
renderopts(op, po) /* set rendering options */ |
654 |
< |
char *op, *po; |
653 |
> |
static void |
654 |
> |
renderopts( /* set rendering options */ |
655 |
> |
char *op, |
656 |
> |
char *po |
657 |
> |
) |
658 |
|
{ |
659 |
|
switch(vscale(QUALITY)) { |
660 |
|
case LOW: |
670 |
|
} |
671 |
|
|
672 |
|
|
673 |
< |
lowqopts(op, po) /* low quality rendering options */ |
674 |
< |
register char *op; |
675 |
< |
char *po; |
673 |
> |
static void |
674 |
> |
lowqopts( /* low quality rendering options */ |
675 |
> |
register char *op, |
676 |
> |
char *po |
677 |
> |
) |
678 |
|
{ |
679 |
|
double d, org[3], siz[3]; |
680 |
|
|
740 |
|
} |
741 |
|
|
742 |
|
|
743 |
< |
medqopts(op, po) /* medium quality rendering options */ |
744 |
< |
register char *op; |
745 |
< |
char *po; |
743 |
> |
static void |
744 |
> |
medqopts( /* medium quality rendering options */ |
745 |
> |
register char *op, |
746 |
> |
char *po |
747 |
> |
) |
748 |
|
{ |
749 |
|
double d, org[3], siz[3], asz; |
750 |
|
|
820 |
|
} |
821 |
|
|
822 |
|
|
823 |
< |
hiqopts(op, po) /* high quality rendering options */ |
824 |
< |
register char *op; |
825 |
< |
char *po; |
823 |
> |
static void |
824 |
> |
hiqopts( /* high quality rendering options */ |
825 |
> |
register char *op, |
826 |
> |
char *po |
827 |
> |
) |
828 |
|
{ |
829 |
|
double d, org[3], siz[3], asz; |
830 |
|
|
898 |
|
} |
899 |
|
|
900 |
|
|
901 |
< |
xferopts(ro) /* transfer options if indicated */ |
902 |
< |
char *ro; |
901 |
> |
static void |
902 |
> |
xferopts( /* transfer options if indicated */ |
903 |
> |
char *ro |
904 |
> |
) |
905 |
|
{ |
906 |
|
int fd, n; |
907 |
|
register char *cp; |
931 |
|
} |
932 |
|
|
933 |
|
|
934 |
< |
pfiltopts(po) /* get pfilt options */ |
935 |
< |
register char *po; |
934 |
> |
static void |
935 |
> |
pfiltopts( /* get pfilt options */ |
936 |
> |
register char *po |
937 |
> |
) |
938 |
|
{ |
939 |
|
*po = '\0'; |
940 |
|
if (vdef(EXPOSURE)) { |
954 |
|
} |
955 |
|
|
956 |
|
|
957 |
< |
matchword(s1, s2) /* match white-delimited words */ |
958 |
< |
register char *s1, *s2; |
957 |
> |
static int |
958 |
> |
matchword( /* match white-delimited words */ |
959 |
> |
register char *s1, |
960 |
> |
register char *s2 |
961 |
> |
) |
962 |
|
{ |
963 |
|
while (isspace(*s1)) s1++; |
964 |
|
while (isspace(*s2)) s2++; |
969 |
|
} |
970 |
|
|
971 |
|
|
972 |
< |
char * |
973 |
< |
specview(vs) /* get proper view spec from vs */ |
974 |
< |
register char *vs; |
972 |
> |
static char * |
973 |
> |
specview( /* get proper view spec from vs */ |
974 |
> |
register char *vs |
975 |
> |
) |
976 |
|
{ |
977 |
|
static char vup[7][12] = {"-vu 0 0 -1","-vu 0 -1 0","-vu -1 0 0", |
978 |
|
"-vu 0 0 1", "-vu 1 0 0","-vu 0 1 0","-vu 0 0 1"}; |
1094 |
|
} |
1095 |
|
|
1096 |
|
|
1097 |
< |
char * |
1098 |
< |
getview(n, vn) /* get view n, or NULL if none */ |
1099 |
< |
int n; |
1100 |
< |
char *vn; /* returned view name */ |
1097 |
> |
static char * |
1098 |
> |
getview( /* get view n, or NULL if none */ |
1099 |
> |
int n, |
1100 |
> |
char *vn /* returned view name */ |
1101 |
> |
) |
1102 |
|
{ |
1103 |
|
register char *mv; |
1104 |
|
|
1136 |
|
} |
1137 |
|
|
1138 |
|
|
1139 |
< |
int |
1140 |
< |
myprintview(vopts, fp) /* print out selected view */ |
1141 |
< |
register char *vopts; |
1142 |
< |
FILE *fp; |
1139 |
> |
static int |
1140 |
> |
myprintview( /* print out selected view */ |
1141 |
> |
register char *vopts, |
1142 |
> |
FILE *fp |
1143 |
> |
) |
1144 |
|
{ |
1145 |
|
VIEW vwr; |
1146 |
|
char buf[128]; |
1147 |
|
register char *cp; |
1148 |
+ |
#ifdef _WIN32 |
1149 |
+ |
/* XXX Should we allow something like this for all platforms? */ |
1150 |
+ |
/* XXX Or is it still required at all? */ |
1151 |
|
again: |
1152 |
+ |
#endif |
1153 |
|
if (vopts == NULL) |
1154 |
|
return(-1); |
1155 |
|
#ifdef _WIN32 |
1172 |
|
} |
1173 |
|
|
1174 |
|
|
1175 |
< |
rview(opts, po) /* run rview with first view */ |
1176 |
< |
char *opts, *po; |
1175 |
> |
static void |
1176 |
> |
rvu( /* run rvu with first view */ |
1177 |
> |
char *opts, |
1178 |
> |
char *po |
1179 |
> |
) |
1180 |
|
{ |
1181 |
|
char *vw; |
1182 |
|
char combuf[PATH_MAX]; |
1185 |
|
return; |
1186 |
|
if (sayview) |
1187 |
|
myprintview(vw, stdout); |
1188 |
< |
sprintf(combuf, "rview %s%s%s -R %s ", vw, po, opts, rifname); |
1188 |
> |
sprintf(combuf, "rvu %s%s%s -R %s ", vw, po, opts, rifname); |
1189 |
|
if (rvdevice != NULL) |
1190 |
|
sprintf(combuf+strlen(combuf), "-o %s ", rvdevice); |
1191 |
|
if (vdef(EXPOSURE)) |
1192 |
|
sprintf(combuf+strlen(combuf), "-pe %s ", vval(EXPOSURE)); |
1193 |
|
strcat(combuf, oct1name); |
1194 |
|
if (runcom(combuf)) { /* run it */ |
1195 |
< |
fprintf(stderr, "%s: error running rview\n", progname); |
1195 |
> |
fprintf(stderr, "%s: error running rvu\n", progname); |
1196 |
|
quit(1); |
1197 |
|
} |
1198 |
|
} |
1199 |
|
|
1200 |
|
|
1201 |
< |
rpict(opts, po) /* run rpict and pfilt for each view */ |
1202 |
< |
char *opts, *po; |
1201 |
> |
static void |
1202 |
> |
rpict( /* run rpict and pfilt for each view */ |
1203 |
> |
char *opts, |
1204 |
> |
char *po |
1205 |
> |
) |
1206 |
|
{ |
1207 |
|
char combuf[PATH_MAX]; |
1208 |
|
char rawfile[PATH_MAX], picfile[PATH_MAX]; |
1320 |
|
zopt, oct1name, rawfile); |
1321 |
|
if (pfile != NULL && inchild()) { |
1322 |
|
/* rpict persistent mode */ |
1323 |
< |
if (!silent) |
1323 |
> |
if (!silent) { |
1324 |
|
printf("\t%s\n", combuf); |
1325 |
+ |
fflush(stdout); |
1326 |
+ |
} |
1327 |
|
sprintf(combuf, "rpict%s %s %s%s%s %s > %s", |
1328 |
|
rep, rppopt, res, po, opts, |
1329 |
|
oct1name, rawfile); |
1361 |
|
mvfile(rawfile, combuf); |
1362 |
|
} else |
1363 |
|
rmfile(rawfile); |
1364 |
< |
finish_process(); /* leave if child */ |
1364 |
> |
finish_process(); /* exit if child */ |
1365 |
|
} |
1366 |
|
wait_process(1); /* wait for children to finish */ |
1367 |
|
if (pfile != NULL) { /* clean up rpict persistent mode */ |
1368 |
< |
int pid; |
1368 |
> |
RT_PID pid; |
1369 |
|
fp = fopen(pfile, "r"); |
1370 |
|
if (fp != NULL) { |
1371 |
|
if (fscanf(fp, "%*s %d", &pid) != 1 || |
1372 |
< |
kill(pid, 1) == -1) |
1372 |
> |
kill(pid, 1) < 0) |
1373 |
|
unlink(pfile); |
1374 |
|
fclose(fp); |
1375 |
|
} |
1381 |
|
} |
1382 |
|
|
1383 |
|
|
1384 |
< |
touch(fn) /* update a file */ |
1385 |
< |
char *fn; |
1384 |
> |
static int |
1385 |
> |
touch( /* update a file */ |
1386 |
> |
char *fn |
1387 |
> |
) |
1388 |
|
{ |
1389 |
|
if (!silent) |
1390 |
|
printf("\ttouch %s\n", fn); |
1399 |
|
} |
1400 |
|
|
1401 |
|
|
1402 |
< |
runcom(cs) /* run command */ |
1403 |
< |
char *cs; |
1402 |
> |
static int |
1403 |
> |
runcom( /* run command */ |
1404 |
> |
char *cs |
1405 |
> |
) |
1406 |
|
{ |
1407 |
|
if (!silent) /* echo it */ |
1408 |
|
printf("\t%s\n", cs); |
1413 |
|
} |
1414 |
|
|
1415 |
|
|
1416 |
< |
rmfile(fn) /* remove a file */ |
1417 |
< |
char *fn; |
1416 |
> |
static int |
1417 |
> |
rmfile( /* remove a file */ |
1418 |
> |
char *fn |
1419 |
> |
) |
1420 |
|
{ |
1421 |
|
if (!silent) |
1422 |
|
printf("\t%s %s\n", DELCMD, fn); |
1426 |
|
} |
1427 |
|
|
1428 |
|
|
1429 |
< |
mvfile(fold, fnew) /* move a file */ |
1430 |
< |
char *fold, *fnew; |
1429 |
> |
static int |
1430 |
> |
mvfile( /* move a file */ |
1431 |
> |
char *fold, |
1432 |
> |
char *fnew |
1433 |
> |
) |
1434 |
|
{ |
1435 |
|
if (!silent) |
1436 |
|
printf("\t%s %s %s\n", RENAMECMD, fold, fnew); |
1441 |
|
|
1442 |
|
|
1443 |
|
#ifdef RHAS_FORK_EXEC |
1444 |
< |
int |
1445 |
< |
next_process() /* fork the next process (max. nprocs) */ |
1444 |
> |
static int |
1445 |
> |
next_process(void) /* fork the next process (max. nprocs) */ |
1446 |
|
{ |
1447 |
< |
int child_pid; |
1447 |
> |
RT_PID child_pid; |
1448 |
|
|
1449 |
|
if (nprocs <= 1) |
1450 |
|
return(0); /* it's us or no one */ |
1451 |
|
if (inchild()) { |
1452 |
< |
fprintf(stderr, "%s: internal error 1 in spawn_process()\n", |
1452 |
> |
fprintf(stderr, "%s: internal error 1 in next_process()\n", |
1453 |
|
progname); |
1454 |
|
quit(1); |
1455 |
|
} |
1469 |
|
return(0); |
1470 |
|
} |
1471 |
|
|
1472 |
< |
wait_process(all) /* wait for process(es) to finish */ |
1473 |
< |
int all; |
1472 |
> |
static void |
1473 |
> |
wait_process( /* wait for process(es) to finish */ |
1474 |
> |
int all |
1475 |
> |
) |
1476 |
|
{ |
1477 |
|
int ourstatus = 0; |
1478 |
< |
int pid, status; |
1478 |
> |
RT_PID pid, status; |
1479 |
|
|
1480 |
|
if (all) |
1481 |
|
all = children_running; |
1499 |
|
quit(ourstatus); /* bad status from child */ |
1500 |
|
} |
1501 |
|
#else /* ! RHAS_FORK_EXEC */ |
1502 |
< |
int |
1503 |
< |
next_process() |
1502 |
> |
static int |
1503 |
> |
next_process(void) |
1504 |
|
{ |
1505 |
|
return(0); /* cannot start new process */ |
1506 |
|
} |
1507 |
+ |
static void |
1508 |
|
wait_process(all) |
1509 |
|
int all; |
1510 |
|
{ |
1512 |
|
} |
1513 |
|
int |
1514 |
|
kill(pid, sig) /* win|unix_process.c should also wait and kill */ |
1515 |
< |
int pid, sig; |
1515 |
> |
RT_PID pid, sig; |
1516 |
|
{ |
1517 |
|
return 0; |
1518 |
|
} |
1519 |
|
#endif /* ! RHAS_FORK_EXEC */ |
1520 |
|
|
1521 |
< |
finish_process() /* exit a child process */ |
1521 |
> |
static void |
1522 |
> |
finish_process(void) /* exit a child process */ |
1523 |
|
{ |
1524 |
|
if (!inchild()) |
1525 |
|
return; /* in parent -- noop */ |
1546 |
|
#endif |
1547 |
|
|
1548 |
|
|
1549 |
< |
badvalue(vc) /* report bad variable value and exit */ |
1550 |
< |
int vc; |
1549 |
> |
static void |
1550 |
> |
badvalue( /* report bad variable value and exit */ |
1551 |
> |
int vc |
1552 |
> |
) |
1553 |
|
{ |
1554 |
|
fprintf(stderr, "%s: bad value for variable '%s'\n", |
1555 |
|
progname, vnam(vc)); |
1557 |
|
} |
1558 |
|
|
1559 |
|
|
1560 |
< |
syserr(s) /* report a system error and exit */ |
1561 |
< |
char *s; |
1560 |
> |
static void |
1561 |
> |
syserr( /* report a system error and exit */ |
1562 |
> |
char *s |
1563 |
> |
) |
1564 |
|
{ |
1565 |
|
perror(s); |
1566 |
|
quit(1); |