forked from enlightenment/efl
parent
7f93656d7b
commit
69d0626265
|
@ -522,7 +522,7 @@ efreet_ini_localestring_get(Efreet_Ini *ini, const char *key)
|
|||
if (country) maxlen += strlen(country);
|
||||
if (modifier) maxlen += strlen(modifier);
|
||||
|
||||
buf = malloc(maxlen * sizeof(char));
|
||||
buf = alloca(maxlen * sizeof(char));
|
||||
|
||||
if (lang && modifier && country)
|
||||
{
|
||||
|
@ -555,8 +555,6 @@ efreet_ini_localestring_get(Efreet_Ini *ini, const char *key)
|
|||
if (!found)
|
||||
val = efreet_ini_string_get(ini, key);
|
||||
|
||||
FREE(buf);
|
||||
|
||||
return val;
|
||||
}
|
||||
|
||||
|
|
|
@ -953,7 +953,7 @@ efreet_menu_dump(Efreet_Menu *menu, const char *indent)
|
|||
size_t len;
|
||||
|
||||
len = strlen(indent) + 3;
|
||||
new_indent = malloc(sizeof(char *) * len);
|
||||
new_indent = alloca(sizeof(char *) * len);
|
||||
snprintf(new_indent, len, "%s ", indent);
|
||||
|
||||
EINA_LIST_FOREACH(menu->entries, l, entry)
|
||||
|
@ -967,8 +967,6 @@ efreet_menu_dump(Efreet_Menu *menu, const char *indent)
|
|||
else if (entry->type == EFREET_MENU_ENTRY_HEADER)
|
||||
INF("%s|---%s", new_indent, entry->name);
|
||||
}
|
||||
|
||||
FREE(new_indent);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue