mirror of
https://github.com/libretro/RetroArch
synced 2025-03-03 04:14:00 +00:00
xmb_node_allocate_userdata - cleanups
This commit is contained in:
parent
ea891cae91
commit
017a61683b
@ -634,19 +634,14 @@ static xmb_node_t *xmb_node_allocate_userdata(xmb_handle_t *xmb,
|
||||
if (!info)
|
||||
return NULL;
|
||||
|
||||
info->userdata = (xmb_node_t*)calloc(1, sizeof(xmb_node_t));
|
||||
node = (xmb_node_t*)calloc(1, sizeof(xmb_node_t));
|
||||
|
||||
if (!info->userdata)
|
||||
if (!node)
|
||||
{
|
||||
RARCH_ERR("XMB node could not be allocated.\n");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
node = (xmb_node_t*)info->userdata;
|
||||
|
||||
if (!node)
|
||||
return NULL;
|
||||
|
||||
node->alpha = xmb->categories.passive.alpha;
|
||||
node->zoom = xmb->categories.passive.zoom;
|
||||
|
||||
@ -656,6 +651,8 @@ static xmb_node_t *xmb_node_allocate_userdata(xmb_handle_t *xmb,
|
||||
node->zoom = xmb->categories.active.zoom;
|
||||
}
|
||||
|
||||
info->userdata = node;
|
||||
|
||||
return node;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user