This commit is contained in:
twinaphex 2016-01-08 20:51:30 +01:00
parent 1014513e91
commit 93fed31e3a
2 changed files with 3 additions and 2 deletions

View File

@ -79,7 +79,6 @@ void d3d_texture_free(LPDIRECT3DTEXTURE tex)
{
if (tex)
tex->Release();
tex = NULL;
}
bool d3d_vertex_declaration_new(LPDIRECT3DDEVICE dev,

View File

@ -1782,10 +1782,12 @@ static uintptr_t d3d_load_texture(void *video_data, void *data,
static void d3d_unload_texture(void *data, uintptr_t *id)
{
LPDIRECT3DTEXTURE texid = (LPDIRECT3DTEXTURE)id;
if (!id)
return;
d3d_texture_free((LPDIRECT3DTEXTURE)id);
d3d_texture_free(texid);
*id = NULL;
}
static const video_poke_interface_t d3d_poke_interface = {