diff options
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/PluginUpdater/src/checksum.cpp | 9 | ||||
-rw-r--r-- | plugins/PluginUpdater/src/stdafx.h | 1 |
2 files changed, 7 insertions, 3 deletions
diff --git a/plugins/PluginUpdater/src/checksum.cpp b/plugins/PluginUpdater/src/checksum.cpp index 2a1fd1b5a9..73d8a30734 100644 --- a/plugins/PluginUpdater/src/checksum.cpp +++ b/plugins/PluginUpdater/src/checksum.cpp @@ -19,6 +19,8 @@ int debug = 0;
DWORD dwVersion = 0;
+#pragma comment(lib, "version.lib")
+
struct MFileMapping
{
PBYTE ptr;
@@ -205,8 +207,11 @@ LBL_NotPE: // patch version
if (dwVersion) {
shift = dwVersion - pISH->VirtualAddress + pISH->PointerToRawData;
- VS_FIXEDFILEINFO *pVersion = (VS_FIXEDFILEINFO*)(map.ptr + shift);
- pVersion->dwProductVersionLS = pVersion->dwProductVersionMS = 0;
+
+ UINT blockSize;
+ VS_FIXEDFILEINFO *vsffi;
+ VerQueryValue(map.ptr + shift, L"\\", (PVOID*)&vsffi, &blockSize);
+ vsffi->dwProductVersionLS = vsffi->dwProductVersionMS = 0;
}
}
diff --git a/plugins/PluginUpdater/src/stdafx.h b/plugins/PluginUpdater/src/stdafx.h index e90119bcd6..00be8fc56f 100644 --- a/plugins/PluginUpdater/src/stdafx.h +++ b/plugins/PluginUpdater/src/stdafx.h @@ -229,7 +229,6 @@ wchar_t* GetDefaultUrl(); bool DownloadFile(FILEURL *pFileURL, HNETLIBCONN &nlc);
void ShowPopup(LPCTSTR Title, LPCTSTR Text, int Number);
-void __stdcall RestartMe(void*);
void __stdcall OpenPluginOptions(void*);
void CheckUpdateOnStartup();
void InitTimer(void *type);
|