changeset 37:67b1b8cec8c0

Fix a problem on Win32 with outout redirected to console
author lbajardsilogic
date Tue, 15 May 2007 08:51:37 +0000
parents 9b552cc5e0d8
children 00540768de0c
files system/Init.cpp
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/system/Init.cpp	Tue May 15 08:03:48 2007 +0000
+++ b/system/Init.cpp	Tue May 15 08:51:37 2007 +0000
@@ -51,11 +51,11 @@
 
 void redirectStderr()
 {
-    HANDLE stderrHandle = GetStdHandle(STD_ERROR_HANDLE);
+	AllocConsole();
+    
+	HANDLE stderrHandle = GetStdHandle(STD_ERROR_HANDLE);
     if (!stderrHandle) return;
 
-    AllocConsole();
-
     CONSOLE_SCREEN_BUFFER_INFO info;
     GetConsoleScreenBufferInfo(stderrHandle, &info);
     info.dwSize.Y = 1000;