ole32: Check for interface NULL which happens with e.g. Abiword.

This commit is contained in:
Marcus Meissner 2010-09-16 17:12:33 +02:00 committed by Alexandre Julliard
parent 5f6f0815de
commit 8d25534613
1 changed files with 2 additions and 0 deletions

View File

@ -450,7 +450,9 @@ HRESULT WINAPI RegisterDragDrop(HWND hwnd, LPDROPTARGET pDropTarget)
hr = CreateStreamOnHGlobal(NULL, TRUE, &stream);
if(FAILED(hr)) return hr;
unk = NULL;
hr = IDropTarget_QueryInterface(pDropTarget, &IID_IUnknown, (void**)&unk);
if (SUCCEEDED(hr) && !unk) hr = E_NOINTERFACE;
if(FAILED(hr))
{
IStream_Release(stream);