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

Comparing ray/src/util/rtcontrib.c (file contents):
Revision 1.25 by greg, Tue Sep 13 22:58:22 2005 UTC vs.
Revision 1.28 by greg, Wed Sep 21 17:17:24 2005 UTC

# Line 330 | Line 330 | main(int argc, char *argv[])
330          quit(0);
331   }
332  
333 + #ifndef SIGALRM
334 + #define SIGALRM SIGTERM
335 + #endif
336   /* kill persistent rtrace process */
337   static void
338   killpersist(void)
339   {
340          FILE    *fp = fopen(persistfn, "r");
341 <        int     pid;
341 >        RT_PID  pid;
342  
343          if (fp == NULL)
344                  return;
# Line 713 | Line 716 | add_contrib(const char *modn)
716          bn = (int)(evalue(mp->binv) + .5);
717          if (bn <= 0)
718                  bn = 0;
719 <        else if (bn > mp->nbins) {      /* new bin */
719 >        else if (bn >= mp->nbins) {     /* new bin */
720                  mp = (MODCONT *)realloc(mp, sizeof(MODCONT) +
721                                                  bn*sizeof(DCOLOR));
722                  if (mp == NULL)
# Line 912 | Line 915 | wait_rproc(void)
915                                  if (rt->bsiz + BUFSIZ <= treebufsiz)
916                                          rt->bsiz = treebufsiz;
917                                  else
918 <                                        rt->bsiz = treebufsiz += BUFSIZ;
918 >                                        treebufsiz = rt->bsiz += BUFSIZ;
919                                  rt->buf = (char *)realloc(rt->buf, rt->bsiz);
920                          }
921                          if (rt->buf == NULL)
# Line 1106 | Line 1109 | recover_output(FILE *fin)
1109                                                  /* seek on all files */
1110          nvals = lastout * outvsiz;
1111          lu_doall(&ofiletab, myseeko, &nvals);
1112 <                                                /* discard input */
1112 >                                                /* skip repeated input */
1113          for (nvals = 0; nvals < lastout; nvals++)
1114                  if (getinp(oname, fin) <= 0)
1115                          error(USER, "unexpected EOF on input");

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines