diff --git "a/dll/win32/version/version.c" "b/dll/win32/version/version.c" index 0e2f35dd107..f1a31c6b1a5 100644 --- "a/dll/win32/version/version.c" +++ "b/dll/win32/version/version.c" @@ -979,6 +979,12 @@ static BOOL VersionInfo32_QueryValue( const VS_VERSION_INFO_STRUCT32 *info, LPCW /* Return value */ *lplpBuffer = VersionInfo32_Value( info ); + + /* If the wValueLength is zero, then back up one WCHAR. This will + * point to the UNICODE_NULL there from the szKey's terminator. */ + if (!info->wValueLength) + *lplpBuffer = (PVOID*)((LONG)*lplpBuffer - 2); + if (puLen) *puLen = info->wValueLength; if (pbText)