mirror of
https://github.com/smartcmd/MinecraftConsoles.git
synced 2026-08-20 09:57:09 +00:00
remove/replace ai generated comments
This commit is contained in:
parent
acd67eaa75
commit
a26e594a6a
|
|
@ -58,9 +58,6 @@ target_compile_definitions(MinecraftClient PRIVATE
|
|||
)
|
||||
if(MSVC)
|
||||
configure_msvc_target(MinecraftClient)
|
||||
# Use CONSOLE subsystem so the shell waits for the process (important for
|
||||
# Docker and piped output in server mode). WinMainCRTStartup keeps the
|
||||
# WinMain entry point. Client mode calls FreeConsole() to detach.
|
||||
target_link_options(MinecraftClient PRIVATE
|
||||
/SUBSYSTEM:CONSOLE
|
||||
/ENTRY:WinMainCRTStartup
|
||||
|
|
|
|||
|
|
@ -228,10 +228,7 @@ static BOOL WINAPI HeadlessServerCtrlHandler(DWORD ctrlType)
|
|||
|
||||
static void SetupHeadlessServerConsole()
|
||||
{
|
||||
// The exe is linked as /SUBSYSTEM:CONSOLE, so it normally inherits the
|
||||
// parent's console. However, if launched with DETACHED_PROCESS or
|
||||
// CREATE_NO_WINDOW the handles may be invalid. Verify before redirecting
|
||||
// the CRT streams to avoid leaving them in a broken state.
|
||||
// Verify console handles are valid before redirecting CRT streams
|
||||
HANDLE hStdOut = GetStdHandle(STD_OUTPUT_HANDLE);
|
||||
HANDLE hStdIn = GetStdHandle(STD_INPUT_HANDLE);
|
||||
bool hasConsole =
|
||||
|
|
|
|||
Loading…
Reference in a new issue