d3dx9_36: Free object on error (coverity).
This commit is contained in:
parent
3abc425267
commit
904cdc46eb
|
@ -2559,6 +2559,7 @@ HRESULT WINAPI D3DXCreateMesh(DWORD numfaces, DWORD numvertices, DWORD options,
|
|||
object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(ID3DXMeshImpl));
|
||||
if (object == NULL || attrib_buffer == NULL)
|
||||
{
|
||||
HeapFree(GetProcessHeap(), 0, object);
|
||||
HeapFree(GetProcessHeap(), 0, attrib_buffer);
|
||||
IDirect3DIndexBuffer9_Release(index_buffer);
|
||||
IDirect3DVertexBuffer9_Release(vertex_buffer);
|
||||
|
|
Loading…
Reference in New Issue