Tag: windows stdout redirect
-
Redirect all stdout/stderr to console
If your Windows executable is using /SUBSYSTEM:WINDOWS rather than /SUBSYSTEM:CONSOLE, something you will have noticed your output messages to stdout (printf, std::cout etc) will be missing. You can easily solve this however by spawning your own Windows console window and redirecting stdout to your new console. The code below will redirect all stdout & stderr…