Commit a5fdea0e authored by Michael Stefaniuc's avatar Michael Stefaniuc Committed by Alexandre Julliard

janitorial: Remove two fresh redundant NULL checks before HeapFree(). Found by Smatch.

parent cfd561f6
......@@ -1753,8 +1753,7 @@ HRESULT WINAPI SHPathPrepareForWriteW(HWND hwnd, IUnknown *modless, LPCWSTR path
/* check if we can access the directory */
res = GetFileAttributesW(realpath);
if (temppath)
HeapFree(GetProcessHeap(), 0, temppath);
HeapFree(GetProcessHeap(), 0, temppath);
if (res == INVALID_FILE_ATTRIBUTES)
{
......
......@@ -796,7 +796,7 @@ static HRESULT WINAPI IWineD3DSurfaceImpl_LockRect(IWineD3DSurface *iface, WINED
checkGLcall("glBindBufferARB");
/* We don't need the system memory anymore and we can't even use it for PBOs */
if(This->resource.allocatedMemory) HeapFree(GetProcessHeap(), 0, This->resource.allocatedMemory);
HeapFree(GetProcessHeap(), 0, This->resource.allocatedMemory);
This->resource.allocatedMemory = NULL;
This->Flags |= SFLAG_PBO;
LEAVE_GL();
......
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