Skip to content

Commit 9436643

Browse files
committed
Update ClipboardPekoify.cpp
1 parent a188f08 commit 9436643

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

ClipboardPekoify.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -467,6 +467,7 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPSTR, int)
467467
MessageBoxExW(NULL, LOC_INSTERRCOPYFILE, LOC_PEKOIFY, MB_OK | MB_ICONERROR, 0);
468468
return 1;
469469
}
470+
LPWSTR installedPath = path;
470471
// Create start menu shortcut
471472
wchar_t shortcutPath[MAX_PATH];
472473
if (SHGetFolderPathW(NULL, CSIDL_PROGRAMS, NULL, 0, shortcutPath) != S_OK) {
@@ -526,7 +527,7 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPSTR, int)
526527
// Destroy the mutex which will allow the new instance to run
527528
CloseHandle(hMutex);
528529
// Quit the current instance and restart from LocalAppData
529-
ShellExecuteW(NULL, L"open", path, NULL, NULL, SW_SHOW);
530+
ShellExecuteW(NULL, L"open", installedPath, NULL, NULL, SW_SHOW);
530531
return 0;
531532
}
532533
// If the user does not want to install, we

0 commit comments

Comments
 (0)