diff --git a/dll/win32/version/version.c b/dll/win32/version/version.c index 0e2f35dd107..8ecabae01a3 100644 --- a/dll/win32/version/version.c +++ b/dll/win32/version/version.c @@ -979,6 +979,14 @@ static BOOL VersionInfo32_QueryValue( const VS_VERSION_INFO_STRUCT32 *info, LPCW /* Return value */ *lplpBuffer = VersionInfo32_Value( info ); + +#ifdef __REACTOS__ + /* If the wValueLength is zero, then set a UNICODE_NULL only return string. + * Use the NULL terminator from the key string for that. This is what Windows does, too. */ + if (!info->wValueLength) + *lplpBuffer = (PVOID)(info->szKey + wcslen(info->szKey)); +#endif + if (puLen) *puLen = info->wValueLength; if (pbText)