fixed bug in FreeConsole()

svn path=/trunk/; revision=382
This commit is contained in:
Eric Kohl 1999-04-14 23:43:56 +00:00
parent 5d97b74881
commit 97c260445b

View file

@ -199,8 +199,16 @@ FreeConsole( VOID )
}
SetLastError(ERROR_SUCCESS);
CloseHandle(StdInput);
CloseHandle(StdOutput);
if (StdError != INVALID_HANDLE_VALUE)
{
if (StdError != StdOutput)
CloseHandle(StdError);
StdError = INVALID_HANDLE_VALUE;
}
CloseHandle(StdOutput);
#ifdef EXTENDED_CONSOLE
CloseHandle(StdAux);
CloseHandle(StdPrint);