Jacek Caban (@jacek) commented about dlls/mshtml/htmldoc.c:
static HRESULT WINAPI MarkupServices_CreateMarkupContainer(IMarkupServices *iface, IMarkupContainer **ppMarkupContainer) { HTMLDocumentNode *This = impl_from_IMarkupServices(iface);
- FIXME("(%p)->(%p)\n", This, ppMarkupContainer);
- return E_NOTIMPL;
- IHTMLDocument2 *frag;
- HRESULT hres;
- TRACE("(%p)->(%p)\n", This, ppMarkupContainer);
- hres = IHTMLDocument3_createDocumentFragment(&This->IHTMLDocument3_iface, &frag);
- if(hres != S_OK)
return hres;
- hres = IHTMLDocument2_QueryInterface(frag, &IID_IMarkupContainer, (void**)ppMarkupContainer);
- if(hres != S_OK)
return hres;
You leak `frag` on this return. In this case, you could just skip that `if()` and return `hres` in the end (or see the other comment).