mirror of
https://github.com/reactos/reactos.git
synced 2026-07-07 10:40:20 +08:00
store startup path statically
svn path=/trunk/; revision=13328
This commit is contained in:
@@ -50,13 +50,12 @@ HWND MainFrameBase::Create(LPCTSTR path, bool mdi, UINT cmdshow)
|
||||
hMainFrame = SDIMainFrame::Create();
|
||||
|
||||
if (hMainFrame) {
|
||||
String sPath;
|
||||
HWND hwndOld = g_Globals._hMainWnd;
|
||||
|
||||
g_Globals._hMainWnd = hMainFrame;
|
||||
|
||||
if (path) {
|
||||
sPath = path; // copy path to avoid accessing freed memory
|
||||
static String sPath = path; // copy path to avoid accessing freed memory
|
||||
path = sPath;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user