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

Comparing ray/src/common/readobj.c (file contents):
Revision 2.26 by greg, Sat Dec 7 02:05:30 2024 UTC vs.
Revision 2.29 by greg, Sat Jun 7 05:09:45 2025 UTC

# Line 14 | Line 14 | static const char RCSid[] = "$Id$";
14   #include  <stdio.h>
15  
16   #include  "platform.h"
17 #include  "paths.h"
17   #include  "standard.h"
18   #include  "object.h"
19   #include  "otypes.h"
# Line 64 | Line 63 | readobj(                               /* read in an object file or stream */
63                          getobject(inpspec, infp);
64                  }
65          }
66 <        if (inpspec[0] == '!')
67 <                pclose(infp);
68 <        else if (infp != stdin)
66 >        if (inpspec[0] == '!') {
67 >                if (pclose(infp) != 0) {
68 >                        sprintf(errmsg, "bad status from \"%s\"", inpspec);
69 >                        error(WARNING, errmsg);
70 >                }
71 >        } else if (infp != stdin)
72                  fclose(infp);
73   #ifdef getc_unlocked
74          else

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines