(SIGAR-186) fix Win32.getFileVersion on windows 2000
This commit is contained in:
1 parent
6b9ac77afa
commit
6eef4f7cdc
1 file changed
+1
-1
Regular → Executable
+1
-1
@@ -3705,7 +3705,7 @@ int sigar_file_version_get(sigar_file_version_t *version,
|
||||
data = malloc(len);
|
||||
|
||||
if (GetFileVersionInfo(name, handle, len, data)) {
|
||||
if (VerQueryValue(data, "\\", &info, 0)) {
|
||||
if (VerQueryValue(data, "\\", &info, &len)) {
|
||||
version->product_major = HIWORD(info->dwProductVersionMS);
|
||||
version->product_minor = LOWORD(info->dwProductVersionMS);
|
||||
version->product_build = HIWORD(info->dwProductVersionLS);
|
||||
|
||||
Reference in new issue
Block a user