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

Comparing ray/src/util/getinfo.c (file contents):
Revision 2.23 by greg, Mon Mar 21 00:21:13 2022 UTC vs.
Revision 2.25 by greg, Wed Apr 13 15:43:06 2022 UTC

# Line 62 | Line 62 | adjheadline(                   /* check for lines to remove */
62                  }
63                  if (s1 == s)
64                          continue;
65 <                if (isspace(*s1) && !*s2 | isspace(*s2))
66 <                        return(0);      /* skip */
65 >                if ((*s1 == '=') & !*s2)
66 >                        return(0);
67 >                if (isspace(*s1) & isspace(*s2))
68 >                        return(0);
69          }
70          fputs(s, stdout);       /* copy if no match */
71          return(0);
# Line 135 | Line 137 | main(
137          }
138   #ifdef getc_unlocked                            /* avoid lock/unlock overhead */
139          flockfile(stdin);
140 +        flockfile(stdout);
141   #endif
142          SET_FILE_BINARY(stdin);
143          if (argc > 2 && !strcmp(argv[1], "-c")) {
# Line 228 | Line 231 | main(
231                  if ((fp = fopen(argv[i], "r")) == NULL)
232                          fputs(": cannot open\n", stdout);
233                  else {
234 + #ifdef getc_unlocked                            /* avoid lock/unlock overhead */
235 +                        flockfile(fp);
236 + #endif
237                          if (dim < 0) {                  /* dimensions only */
238                                  if (getheader(fp, NULL, NULL) < 0) {
239                                          fputs("bad header!\n", stdout);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines