From 61364c874f09f61870b66a6414496f741a2030ac Mon Sep 17 00:00:00 2001 From: AnyOldName3 Date: Tue, 16 Apr 2024 01:14:20 +0100 Subject: [PATCH] Warn future me off wasting their time again --- components/debug/debugging.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/components/debug/debugging.cpp b/components/debug/debugging.cpp index 0699d0912b..e6caf2b09d 100644 --- a/components/debug/debugging.cpp +++ b/components/debug/debugging.cpp @@ -61,6 +61,10 @@ namespace Debug bool outRedirected = isRedirected(STD_OUTPUT_HANDLE); bool errRedirected = isRedirected(STD_ERROR_HANDLE); + // Note: Do not spend three days reinvestigating this PowerShell bug thinking its our bug. + // https://gitlab.com/OpenMW/openmw/-/merge_requests/408#note_447467393 + // The handles look valid, but GetFinalPathNameByHandleA can't tell what files they go to and writing to them doesn't work. + if (AttachConsole(ATTACH_PARENT_PROCESS)) { fflush(stdout);