Support macos

This commit is contained in:
js6pak authored and ghorsington committed 2022-08-14 17:18:58 +03:00
1 parent 12079aeb09
commit 3538abf277
1 file changed
+4 -1
@@ -64,7 +64,10 @@ internal class ConsoleWindow
var currWnd = getForeground();
if (!AllocConsole())
throw new Win32Exception("AllocConsole() failed");
{
var error = Marshal.GetLastWin32Error();
if (error != 5) throw new Win32Exception("AllocConsole() failed");
}
// Restore Foreground
setForeground(currWnd);