ntdll: Added parsing of public key token in manifests.

This commit is contained in:
Eric Pouech 2007-07-19 17:54:53 +02:00 committed by Alexandre Julliard
parent 2bc3c39cc0
commit a22dcd1ad0

View file

@ -90,6 +90,7 @@ struct assembly_identity
{
WCHAR *name;
WCHAR *arch;
WCHAR *public_key;
struct version version;
enum assembly_id_type type;
};
@ -181,6 +182,7 @@ struct actctx_loader
#define MANIFESTVERSION_ATTR "manifestVersion"
#define NAME_ATTR "name"
#define PROCESSORARCHITECTURE_ATTR "processorArchitecture"
#define PUBLICKEYTOKEN_ATTR "publicKeyToken"
#define TLBID_ATTR "tlbid"
#define TYPE_ATTR "type"
#define VERSION_ATTR "version"
@ -287,6 +289,7 @@ static void free_assembly_identity(struct assembly_identity *ai)
{
RtlFreeHeap( GetProcessHeap(), 0, ai->name );
RtlFreeHeap( GetProcessHeap(), 0, ai->arch );
RtlFreeHeap( GetProcessHeap(), 0, ai->public_key );
}
static struct entity* add_entity(struct dll_redirect* dll, DWORD kind)
@ -627,6 +630,10 @@ static BOOL parse_assembly_identity_elem(xmlbuf_t* xmlbuf, ACTIVATION_CONTEXT* a
{
if (!(ai->arch = xmlstrdupW(&attr_value))) return FALSE;
}
else if (xmlstr_cmp(&attr_name, PUBLICKEYTOKEN_ATTR))
{
if (!(ai->public_key = xmlstrdupW(&attr_value))) return FALSE;
}
else
{
WARN("unknown attr %s=%s\n", debugstr_xmlstr(&attr_name),