(menu_setting) Test needle before checking setting type

This commit is contained in:
Higor Eurípedes 2015-06-14 16:04:26 -03:00
parent 725e0cd43d
commit cbeee0ca1d

View File

@ -322,7 +322,7 @@ rarch_setting_t *menu_setting_find(const char *label)
for (; settings->type != ST_NONE; settings++)
{
if (settings->type <= ST_GROUP && needle == settings->name_hash)
if (needle == settings->name_hash && settings->type <= ST_GROUP)
{
/* make sure this isn't a collision */
if (strcmp(label, settings->name) != 0)