From: curt Date: Sun, 20 Jun 1999 01:52:31 +0000 (+0000) Subject: Borland C++ tweaks. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=bb882a12397b6f44ac1d168419d6bac4118139ea;p=simgear.git Borland C++ tweaks. MacOS/Metrowerks tweaks. Fix for fgText default constructor. --- diff --git a/Lib/Bucket/newbucket.cxx b/Lib/Bucket/newbucket.cxx index bb6f8bb9..20d980b9 100644 --- a/Lib/Bucket/newbucket.cxx +++ b/Lib/Bucket/newbucket.cxx @@ -28,6 +28,8 @@ #endif +#include + #include #include "newbucket.hxx" diff --git a/Lib/Misc/fgstream.cxx b/Lib/Misc/fgstream.cxx index 3d5a0933..a7203de2 100644 --- a/Lib/Misc/fgstream.cxx +++ b/Lib/Misc/fgstream.cxx @@ -118,18 +118,29 @@ skipws( istream& in ) { while ( in.get(c) ) { #ifdef __MWERKS__ + // -dw- for unix file compatibility // -clo- this causes problems for unix if ( (c == '\n') || (c == '\r') || (c == '\0') ) { break; - } -#endif + } + + if ( ! isspace( c ) && c != '\n' ) { + // put pack the non-space character + in.putback(c); + break; + } + +#else if ( ! isspace( c ) ) { // put pack the non-space character in.putback(c); break; } + +#endif + } return in; } diff --git a/Lib/XGL/xglUtils.c b/Lib/XGL/xglUtils.c index 56da1652..d781fa23 100644 --- a/Lib/XGL/xglUtils.c +++ b/Lib/XGL/xglUtils.c @@ -7,7 +7,7 @@ #include #include -#if !defined( __CYGWIN__ ) && !defined( __CYGWIN32__ ) +#if !defined( WIN32 ) # if !defined( HAVE_STL_SGI_PORT ) && !defined( __MWERKS__ ) // Avoid malloc with STLport and MSL # include @@ -28,12 +28,7 @@ int xglTraceOn = TRUE ; -#ifndef WIN32 - FILE *xglTraceFd = stdout ; -#else /* WIN32 */ - /* Bail for now, we just want it to compile I guess */ - FILE *xglTraceFd = NULL; -#endif /* WIN32 */ +FILE *xglTraceFd = NULL; struct GLenumLookup {