oleacc: Fix allocation error handling in ObjectFromLresult.

This commit is contained in:
Piotr Caban 2014-10-06 10:57:49 +02:00 committed by Alexandre Julliard
parent 3704072911
commit 964ab4b6f2
1 changed files with 2 additions and 2 deletions

View File

@ -219,10 +219,10 @@ HRESULT WINAPI ObjectFromLresult( LRESULT result, REFIID riid, WPARAM wParam, vo
return E_FAIL;
data = GlobalAlloc(GMEM_FIXED, size);
memcpy(data, view, size);
UnmapViewOfFile(view);
if(!data)
return E_OUTOFMEMORY;
memcpy(data, view, size);
UnmapViewOfFile(view);
hr = CreateStreamOnHGlobal(data, TRUE, &stream);
if(FAILED(hr)) {