Fix: [Win32] don't mess with std[out|err|in] if we can't allocate a console
This commit is contained in:
@@ -300,7 +300,7 @@ void CreateConsole()
|
|||||||
if (_has_console) return;
|
if (_has_console) return;
|
||||||
_has_console = true;
|
_has_console = true;
|
||||||
|
|
||||||
AllocConsole();
|
if (!AllocConsole()) return;
|
||||||
|
|
||||||
hand = GetStdHandle(STD_OUTPUT_HANDLE);
|
hand = GetStdHandle(STD_OUTPUT_HANDLE);
|
||||||
GetConsoleScreenBufferInfo(hand, &coninfo);
|
GetConsoleScreenBufferInfo(hand, &coninfo);
|
||||||
|
Reference in New Issue
Block a user