wined3d: Correctly destroy the adapter on format initialization failure in no3d mode.

Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Matteo Bruni 2020-07-22 19:00:54 +02:00 committed by Alexandre Julliard
parent a5ef9295bc
commit 1e25ff3cc4
1 changed files with 1 additions and 0 deletions

View File

@ -2991,6 +2991,7 @@ static struct wined3d_adapter *wined3d_adapter_no3d_create(unsigned int ordinal,
if (!wined3d_adapter_no3d_init_format_info(adapter))
{
wined3d_adapter_cleanup(adapter);
heap_free(adapter);
return NULL;
}