Commit cdac6b50 authored by Alistair Leslie-Hughes's avatar Alistair Leslie-Hughes Committed by Alexandre Julliard

msxml3: Cannot add an attribute with appendChild.

parent 0a80e7c0
......@@ -482,9 +482,29 @@ static HRESULT WINAPI xmlnode_appendChild(
IXMLDOMNode** outNewChild)
{
xmlnode *This = impl_from_IXMLDOMNode( iface );
IXMLDOMNode *pAttr = NULL;
VARIANT var;
TRACE("(%p)->(%p,%p)\n", This, newChild, outNewChild);
/* Cannot Append an Attribute node. */
IUnknown_QueryInterface(newChild, &IID_IXMLDOMNode, (LPVOID*)&pAttr);
if(pAttr)
{
xmlnode *ThisNew = impl_from_IXMLDOMNode( pAttr );
if(ThisNew->node->type == XML_ATTRIBUTE_NODE)
{
if(outNewChild) *outNewChild = NULL;
IUnknown_Release(pAttr);
return E_FAIL;
}
IUnknown_Release(pAttr);
}
VariantInit(&var);
return IXMLDOMNode_insertBefore(iface, newChild, var, outNewChild);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment