mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-04-28 21:07:59 +03:00
enable win32 debug console when launching from console
This commit is contained in:
parent
d791dcfbf3
commit
64e960aa22
5 changed files with 70 additions and 1 deletions
|
@ -52,6 +52,11 @@ namespace Debug
|
|||
|
||||
int wrapApplication(int (*innerApplication)(int argc, char *argv[]), int argc, char *argv[], const std::string& appName)
|
||||
{
|
||||
#if defined _WIN32
|
||||
// grab a console window if we don't have one
|
||||
(void)Debug::attachParentConsole();
|
||||
#endif
|
||||
|
||||
// Some objects used to redirect cout and cerr
|
||||
// Scope must be here, so this still works inside the catch block for logging exceptions
|
||||
std::streambuf* cout_rdbuf = std::cout.rdbuf ();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue