--- ray/src/common/rglinst.c 2003/05/13 17:58:32 3.8 +++ ray/src/common/rglinst.c 2003/06/05 19:29:34 3.9 @@ -1,5 +1,5 @@ #ifndef lint -static const char RCSid[] = "$Id: rglinst.c,v 3.8 2003/05/13 17:58:32 greg Exp $"; +static const char RCSid[] = "$Id: rglinst.c,v 3.9 2003/06/05 19:29:34 schorsch Exp $"; #endif /* * Routines for reading instances and converting to OpenGL. @@ -9,6 +9,7 @@ static const char RCSid[] = "$Id: rglinst.c,v 3.8 2003 #include "radogl.h" #include "octree.h" +#include "platform.h" #define MAXLEVEL 16 /* maximum instance hierarchy level */ @@ -168,9 +169,7 @@ FVECT cent; sprintf(errmsg, "cannot open octree file \"%s\"", fname); error(SYSTEM, errmsg); } -#ifdef MSDOS - setmode(fileno(infp), O_BINARY); -#endif + SET_FILE_BINARY(infp); /* get header */ if (checkheader(infp, OCTFMT, NULL) < 0) octerror(USER, "not an octree"); @@ -207,9 +206,7 @@ char *fname; infn = fname; infp = fopen(fname, "r"); /* assume already checked */ -#ifdef MSDOS - setmode(fileno(infp), O_BINARY); -#endif + SET_FILE_BINARY(infp); /* skip header */ getheader(infp, NULL, NULL); /* get format */