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

Comparing ray/src/gen/xform.c (file contents):
Revision 2.7 by greg, Fri Oct 2 16:12:46 1992 UTC vs.
Revision 2.8 by greg, Sat Jan 1 09:19:36 1994 UTC

# Line 1 | Line 1
1 < /* Copyright (c) 1992 Regents of the University of California */
1 > /* Copyright (c) 1994 Regents of the University of California */
2  
3   #ifndef lint
4   static char SCCSid[] = "$SunId$ LBL";
# Line 173 | Line 173 | xform(name, fin)                       /* transform stream by tot.xfm */
173   char  *name;
174   register FILE  *fin;
175   {
176 +        int  nobjs = 0;
177          register int  c;
178  
179          while ((c = getc(fin)) != EOF) {
# Line 188 | Line 189 | register FILE  *fin;
189                  } else if (c == '!') {                  /* command */
190                          ungetc(c, fin);
191                          xfcomm(name, fin);
192 +                        nobjs++;
193                  } else {                                /* object */
194                          ungetc(c, fin);
195                          xfobject(name, fin);
196 +                        nobjs++;
197                  }
198          }
199 +        if (nobjs == 0)
200 +                fprintf(stderr, "%s: (%s): warning - empty file\n",
201 +                                progname, name);
202   }
203  
204  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines