mirror of
https://github.com/CTCaer/RetroArch.git
synced 2025-01-01 15:48:49 +00:00
xmb: Fix a potential memleak
This commit is contained in:
parent
14189c08a2
commit
c5512dbd5b
@ -575,13 +575,13 @@ static void *xmb_init(void)
|
||||
menu->userdata = (xmb_handle_t*)calloc(1, sizeof(xmb_handle_t));
|
||||
|
||||
if (!menu->userdata)
|
||||
{
|
||||
free(menu);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
xmb = (xmb_handle_t*)menu->userdata;
|
||||
|
||||
if (!xmb)
|
||||
return NULL;
|
||||
|
||||
xmb->x = 0;
|
||||
xmb->alpha = 1.0f;
|
||||
xmb->depth = 1;
|
||||
|
Loading…
Reference in New Issue
Block a user