Веб-сайт самохостера Lotigara

summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source/application/StarMainApplication.hpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/source/application/StarMainApplication.hpp b/source/application/StarMainApplication.hpp
index 18c9fa5..5ba06e7 100644
--- a/source/application/StarMainApplication.hpp
+++ b/source/application/StarMainApplication.hpp
@@ -18,6 +18,10 @@ namespace Star {
LPWSTR* argsList = CommandLineToArgvW(GetCommandLineW(), &nArgs); \
Star::StringList args; \
for (int i = 0; i < nArgs; ++i) args.append(Star::String(argsList[i])); \
+ if (IsDebuggerPresent() && AllocConsole()) { \
+ freopen("CONOUT$", "w", stdout); \
+ freopen("CONOUT$", "w", stderr); \
+ } \
return Star::runMainApplication(Star::make_unique<ApplicationClass>(), args); \
}