Commit 905fcb87 authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

mshtml: Make IHTMLElement::get_document vtbl offset independent.

parent 2e7fc3e5
......@@ -585,7 +585,7 @@ static HRESULT WINAPI HTMLElement_get_document(IHTMLElement *iface, IDispatch **
if(!p)
return E_POINTER;
*p = (IDispatch*)This->node.doc;
*p = (IDispatch*)HTMLDOC(This->node.doc);
IDispatch_AddRef(*p);
return S_OK;
......
......@@ -3343,6 +3343,11 @@ static void test_elems(IHTMLDocument2 *doc)
ok(type == 1, "type=%ld\n", type);
IHTMLSelectElement_Release(select);
hres = IHTMLElement_get_document(elem, &disp);
ok(hres == S_OK, "get_document failed: %08x\n", hres);
ok(iface_cmp((IUnknown*)disp, (IUnknown*)doc), "disp != doc\n");
IHTMLElement_Release(elem);
}
......
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