| 253 |
|
cp--; |
| 254 |
|
strcpy(cp, RFTEMPLATE); |
| 255 |
|
prvr = mktemp(fbuf2); |
| 256 |
< |
if (rename(fbuf, prvr) < 0) |
| 256 |
> |
if (rename(fbuf, prvr) < 0) { |
| 257 |
|
if (errno == ENOENT) { /* ghost file */ |
| 258 |
|
sprintf(errmsg, |
| 259 |
|
"new output file \"%s\"", |
| 266 |
|
fbuf, prvr); |
| 267 |
|
error(SYSTEM, errmsg); |
| 268 |
|
} |
| 269 |
+ |
} |
| 270 |
|
} |
| 271 |
|
} |
| 272 |
|
npicts = 0; /* render sequence */ |
| 295 |
|
dupheader(); |
| 296 |
|
} |
| 297 |
|
hres = hresolu; vres = vresolu; pa = pixaspect; |
| 298 |
< |
if (prvr != NULL) |
| 298 |
> |
if (prvr != NULL) { |
| 299 |
|
if (viewfile(prvr, &ourview, &rs) <= 0 |
| 300 |
|
|| rs.rt != PIXSTANDARD) { |
| 301 |
|
sprintf(errmsg, |
| 306 |
|
hres = scanlen(&rs); |
| 307 |
|
vres = numscans(&rs); |
| 308 |
|
} |
| 309 |
+ |
} |
| 310 |
|
if ((cp = setview(&ourview)) != NULL) |
| 311 |
|
error(USER, cp); |
| 312 |
|
normaspect(viewaspect(&ourview), &pa, &hres, &vres); |
| 346 |
|
{ |
| 347 |
|
char linebuf[256]; |
| 348 |
|
|
| 349 |
< |
copystruct(&lastview, &ourview); |
| 349 |
> |
lastview = ourview; |
| 350 |
|
while (fgets(linebuf, sizeof(linebuf), fp) != NULL) |
| 351 |
|
if (isview(linebuf) && sscanview(&ourview, linebuf) > 0) |
| 352 |
|
return(0); |