hlink: Return S_FALSE in GetTargetFrameName when returning NULL.

This commit is contained in:
Jacek Caban 2011-10-21 15:16:08 +02:00 committed by Alexandre Julliard
parent 7b2bb14be2
commit 34db2d3926
2 changed files with 8 additions and 1 deletions

View file

@ -437,7 +437,15 @@ static HRESULT WINAPI IHlink_fnGetTargetFrameName(IHlink* iface,
HlinkImpl *This = impl_from_IHlink(iface);
TRACE("(%p)->(%p)\n", This, ppwzTargetFrameName);
if(!This->TargetFrameName) {
*ppwzTargetFrameName = NULL;
return S_FALSE;
}
*ppwzTargetFrameName = hlink_co_strdupW( This->TargetFrameName );
if(!*ppwzTargetFrameName)
return E_OUTOFMEMORY;
return S_OK;
}

View file

@ -745,7 +745,6 @@ static HRESULT WINAPI HlinkFrame_Navigate(IHlinkFrame *iface, DWORD grfHLNF, LPB
DWORD site_data = 0xdeadbeef;
hres = IHlink_GetTargetFrameName(pihlNavigate, &frame_name);
todo_wine
ok(hres == S_FALSE, "GetTargetFrameName failed: %08x\n", hres);
ok(frame_name == NULL, "frame_name = %p\n", frame_name);