summaryrefslogtreecommitdiff
path: root/indra/newview/llappviewerwin32.cpp
diff options
context:
space:
mode:
authorAndrey Kleshchev <117672381+akleshchev@users.noreply.github.com>2026-05-13 23:29:23 +0300
committerAndrey Kleshchev <117672381+akleshchev@users.noreply.github.com>2026-05-14 05:55:25 +0300
commit0422a389ad0289880dc5cead1c8d0788fa881e73 (patch)
tree9760bfb9af36fa497a0f5a3b57d982dbbad6a099 /indra/newview/llappviewerwin32.cpp
parent9cd5eb8cac12b50e1590c1a472886c37aae58b7b (diff)
#5810 Improve early exit's cleanup
Diffstat (limited to 'indra/newview/llappviewerwin32.cpp')
-rw-r--r--indra/newview/llappviewerwin32.cpp18
1 files changed, 11 insertions, 7 deletions
diff --git a/indra/newview/llappviewerwin32.cpp b/indra/newview/llappviewerwin32.cpp
index 3dc98b83c4..4e443ee189 100644
--- a/indra/newview/llappviewerwin32.cpp
+++ b/indra/newview/llappviewerwin32.cpp
@@ -4,7 +4,7 @@
*
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* Second Life Viewer Source Code
- * Copyright (C) 2010, Linden Research, Inc.
+ * Copyright (C) 2026, Linden Research, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -854,12 +854,7 @@ bool LLAppViewerWin32::cleanup()
bool result = LLAppViewer::cleanup();
gDXHardware.cleanup();
-
- if (mIsConsoleAllocated)
- {
- FreeConsole();
- mIsConsoleAllocated = false;
- }
+ cleanupConsole();
return result;
}
@@ -943,6 +938,15 @@ void LLAppViewerWin32::initConsole()
return LLAppViewer::initConsole();
}
+void LLAppViewerWin32::cleanupConsole()
+{
+ if (mIsConsoleAllocated)
+ {
+ FreeConsole();
+ mIsConsoleAllocated = false;
+ }
+}
+
void write_debug_dx(const char* str)
{
std::string value = gDebugInfo["DXInfo"].asString();