From dfd703004cf734cc79109ed133c19fde06b5a4d4 Mon Sep 17 00:00:00 2001 From: Valentin Radu Date: Mon, 13 Dec 2021 19:10:01 +0200 Subject: [PATCH] Fixed "DisplayVersion" not created in program uninstallation registry entry (microsoft/winget-pkgs/pull/37596) --- ep_setup/ep_setup.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ep_setup/ep_setup.c b/ep_setup/ep_setup.c index 886e038..51f7718 100644 --- a/ep_setup/ep_setup.c +++ b/ep_setup/ep_setup.c @@ -94,9 +94,9 @@ BOOL SetupUninstallEntry(BOOL bInstall, WCHAR* wszPath) } if (!dwLastError) { - PathRemoveFileSpecW(wszPath); - wcscat_s(wszPath, MAX_PATH, L"\\" _T(PRODUCT_NAME) L".amd64.dll"); - HMODULE hEP = LoadLibraryExW(wszPath, NULL, LOAD_LIBRARY_AS_DATAFILE); + PathRemoveFileSpecW(wszPath + 1); + wcscat_s(wszPath + 1, MAX_PATH - 2, L"\\" _T(PRODUCT_NAME) L".amd64.dll"); + HMODULE hEP = LoadLibraryExW(wszPath + 1, NULL, LOAD_LIBRARY_AS_DATAFILE); if (hEP) { DWORD dwLeftMost = 0;