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

Comparing ray/src/util/eplus_idf.c (file contents):
Revision 2.4 by greg, Sun Feb 9 05:49:21 2014 UTC vs.
Revision 2.6 by greg, Mon Feb 10 04:51:26 2014 UTC

# Line 44 | Line 44 | idf_newparam(IDF_LOADED *idf, const char *pname, const
44          if (pnew == NULL)
45                  return(NULL);
46          strcpy(pnew->rem, comm);
47 +        pnew->nfield = 0;
48          pnew->flist = NULL;
49          pnew->pname = pent->key;        /* add to table */
50          pnew->pnext = (IDF_PARAMETER *)pent->data;
# Line 76 | Line 77 | idf_addfield(IDF_PARAMETER *param, const char *fval, c
77          if (fnew == NULL)
78                  return(0);
79          fnew->next = NULL;
80 <        cp = fnew->arg;                 /* copy argument and comments */
80 >        cp = fnew->val;                 /* copy value and comments */
81          while ((*cp++ = *fval++))
82                  ;
83          fnew->rem = cp;
# Line 94 | Line 95 | idf_addfield(IDF_PARAMETER *param, const char *fval, c
95                  param->flist = fnew;
96          else
97                  flast->next = fnew;
98 +        param->nfield++;
99          return(fnum);
100   }
101  
# Line 365 | Line 367 | idf_writeparam(IDF_PARAMETER *param, FILE *fp, int inc
367                  fputs(param->rem, fp);
368          for (fptr = param->flist; fptr != NULL; fptr = fptr->next) {
369                  if (!incl_comm)
370 <                        fputs("\n\t", fp);
371 <                fputs(fptr->arg, fp);
370 >                        fputs("\n    ", fp);
371 >                fputs(fptr->val, fp);
372                  fputc((fptr->next==NULL ? ';' : ','), fp);
373                  if (incl_comm)
374                          fputs(fptr->rem, fp);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines