summaryrefslogtreecommitdiff
path: root/src/core/miranda.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/miranda.cpp')
-rw-r--r--src/core/miranda.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/core/miranda.cpp b/src/core/miranda.cpp
index 133b4e1cda..1e13d9ad60 100644
--- a/src/core/miranda.cpp
+++ b/src/core/miranda.cpp
@@ -214,9 +214,10 @@ int WINAPI _tWinMain(HINSTANCE hInstance, HINSTANCE, LPTSTR cmdLine, int)
CmdLine_Parse(cmdLine);
setlocale(LC_ALL, "");
-#ifdef _DEBUG
- _CrtSetDbgFlag(_CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF);
-#endif
+ #ifdef _DEBUG
+ if ( CmdLine_GetOption( _T("memdebug")))
+ _CrtSetDbgFlag(_CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF);
+ #endif
HINSTANCE hUser32 = GetModuleHandleA("user32");
openInputDesktop = (pfnOpenInputDesktop)GetProcAddress (hUser32, "OpenInputDesktop");