diff --git a/dlls/fusion/assembly.c b/dlls/fusion/assembly.c index a3abc4e98d8..418d3b1c3d7 100644 --- a/dlls/fusion/assembly.c +++ b/dlls/fusion/assembly.c @@ -567,7 +567,7 @@ static HRESULT parse_metadata_header(ASSEMBLY *assembly, DWORD *hdrsz) size = FIELD_OFFSET(METADATAHDR, Version); memcpy(assembly->metadatahdr, metadatahdr, size); - /* we don't care about the version string */ + assembly->metadatahdr->Version = (LPSTR)&metadatahdr->Version; ofs = FIELD_OFFSET(METADATAHDR, Flags); ptr += FIELD_OFFSET(METADATAHDR, Version) + metadatahdr->VersionLength + 1; @@ -901,3 +901,9 @@ done: return hr; } + +HRESULT assembly_get_runtime_version(ASSEMBLY *assembly, LPSTR *version) +{ + *version = assembly->metadatahdr->Version; + return S_OK; +} diff --git a/dlls/fusion/fusionpriv.h b/dlls/fusion/fusionpriv.h index 8d51f5d0404..a262d72face 100644 --- a/dlls/fusion/fusionpriv.h +++ b/dlls/fusion/fusionpriv.h @@ -435,6 +435,7 @@ HRESULT assembly_get_path(const ASSEMBLY *assembly, LPWSTR *path) DECLSPEC_HIDDE HRESULT assembly_get_version(ASSEMBLY *assembly, LPWSTR *version) DECLSPEC_HIDDEN; BYTE assembly_get_architecture(ASSEMBLY *assembly) DECLSPEC_HIDDEN; HRESULT assembly_get_pubkey_token(ASSEMBLY *assembly, LPWSTR *token) DECLSPEC_HIDDEN; +HRESULT assembly_get_runtime_version(ASSEMBLY *assembly, LPSTR *version) DECLSPEC_HIDDEN; extern HRESULT IAssemblyName_SetPath(IAssemblyName *iface, LPCWSTR path) DECLSPEC_HIDDEN; extern HRESULT IAssemblyName_GetPath(IAssemblyName *iface, LPWSTR buf, ULONG *len) DECLSPEC_HIDDEN;