// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Library General Public License for more details.
//
-// You should have received a copy of the GNU Library General Public
-// License along with this library; if not, write to the
-// Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-// Boston, MA 02111-1307, USA.
+// You should have received a copy of the GNU General Public License
+// along with this program; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
//
// $Id$
*/
void set_sb( streambuf* sb );
+#ifdef _MSC_VER
+ static void has_no_console() { has_console = false; }
+#endif
+
protected:
/** sync/flush */
static streambuf* sbuf;
static bool logging_enabled;
+#ifdef _MSC_VER
+ static bool has_console;
+#endif
static sgDebugClass logClass;
static sgDebugPriority logPriority;
logbuf::overflow( int c )
{
#ifdef _MSC_VER
- static has_console = false;
if ( logging_enabled ) {
if ( !has_console ) {
AllocConsole();
freopen("conout$", "w", stderr);
has_console = true;
}
- sbuf->sputc(c);
+ return sbuf->sputc(c);
}
else
return EOF == 0 ? 1: 0;