summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tools')
-rw-r--r--tools/checksum/checksum.cpp4
-rw-r--r--tools/checksum/checksum.exebin18432 -> 18432 bytes
2 files changed, 3 insertions, 1 deletions
diff --git a/tools/checksum/checksum.cpp b/tools/checksum/checksum.cpp
index 0e19ab1693..aee6b6102f 100644
--- a/tools/checksum/checksum.cpp
+++ b/tools/checksum/checksum.cpp
@@ -18,7 +18,7 @@
#pragma comment(lib, "version.lib")
int debug = 0;
-DWORD dwVersion = 0;
+DWORD dwVersion;
static void PatchResourcesDirectory(PIMAGE_RESOURCE_DIRECTORY pIRD, PBYTE pBase, DWORD dwType);
@@ -219,6 +219,8 @@ int PEChecksum(wchar_t *filename, BYTE digest[16])
// patch resources
if (resSize > 0 && resAddr >= pISH->VirtualAddress && resAddr + resSize <= pISH->VirtualAddress + pISH->SizeOfRawData) {
+ dwVersion = 0;
+
DWORD shift = resAddr - pISH->VirtualAddress + pISH->PointerToRawData;
IMAGE_RESOURCE_DIRECTORY *pIRD = (IMAGE_RESOURCE_DIRECTORY*)(ptr + shift);
PatchResourcesDirectory(pIRD, ptr + shift, 0);
diff --git a/tools/checksum/checksum.exe b/tools/checksum/checksum.exe
index f4e21190c6..9cc85cb66e 100644
--- a/tools/checksum/checksum.exe
+++ b/tools/checksum/checksum.exe
Binary files differ