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

Comparing ray/src/cal/rcalc.c (file contents):
Revision 1.21 by greg, Sun Jun 14 00:33:16 2009 UTC vs.
Revision 1.22 by greg, Thu Dec 19 16:38:12 2013 UTC

# Line 8 | Line 8 | static const char RCSid[] = "$Id$";
8   */
9  
10   #include  <stdlib.h>
11 #include  <fcntl.h>
12 #include  <stdio.h>
13 #include  <string.h>
11   #include  <math.h>
12   #include  <ctype.h>
13  
# Line 107 | Line 104 | int  argc,
104   char  *argv[]
105   )
106   {
107 +        char  *fpath;
108          int  i;
109  
110          esupport |= E_VARIABLE|E_FUNCTION|E_INCHAN|E_OUTCHAN|E_RCONST;
# Line 136 | Line 134 | char  *argv[]
134                          svpreset(argv[++i]);
135                          break;
136                  case 'f':
137 <                        fcompile(argv[++i]);
137 >                        fpath = getpath(argv[++i], getrlibpath(), 0);
138 >                        if (fpath == NULL) {
139 >                                eputs(argv[0]);
140 >                                eputs(": cannot find file '");
141 >                                eputs(argv[i]);
142 >                                eputs("'\n");
143 >                                quit(1);
144 >                        }
145 >                        fcompile(fpath);
146                          break;
147                  case 'e':
148                          scompile(argv[++i], NULL, 0);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines