ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/util/ranimove.c
(Generate patch)

Comparing ray/src/util/ranimove.c (file contents):
Revision 3.7 by schorsch, Sun Jul 27 22:12:03 2003 UTC vs.
Revision 3.9 by schorsch, Tue Oct 21 19:19:29 2003 UTC

# Line 12 | Line 12 | static const char RCSid[] = "$Id";
12   #include "copyright.h"
13  
14   #include <time.h>
15 < #ifndef _WIN32
15 > #ifdef _WIN32
16 >  #include <winsock.h> /* struct timeval. XXX find a replacement? */
17 > #else
18    #include <sys/time.h>
19   #endif
20   #include <ctype.h>
# Line 141 | Line 143 | char   *argv[];
143                                                  /* all done */
144          if (lorendoptf[0])
145                  unlink(lorendoptf);
146 <        if (hirendoptf[0])
146 >        if (hirendoptf[0] && strcmp(hirendoptf, lorendoptf))
147                  unlink(hirendoptf);
148          if (objtmpf[0])
149                  unlink(objtmpf);
# Line 334 | Line 336 | char           *qval;
336          if (qval != NULL && qval[0] == '-')
337                  ac += wordstring(av+ac, qval);
338  
339 <                                /* start with default parameters */
340 <        ray_defaults(NULL);
339 >                                /* restore default parameters */
340 >        ray_restore(NULL);
341                                  /* set what we have */
342          for (i = 0; i < ac; i++) {
343                  while ((rval = expandarg(&ac, &av, i)) > 0)
# Line 349 | Line 351 | char           *qval;
351                          continue;
352                  }
353                  rval = getrenderopt(ac-i, av+i);
354 <                if (rval >= 0) {
355 <                        i += rval;
356 <                        continue;
354 >                if (rval < 0) {
355 >                        sprintf(errmsg, "bad render option at '%s'", av[i]);
356 >                        error(USER, errmsg);
357                  }
358 <                sprintf(errmsg, "bad render option at '%s'", av[i]);
357 <                error(USER, errmsg);
358 >                i += rval;
359          }
360   }
361  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines