1
0
Fork 0
forked from len0rd/rockbox

Pass the buffer length to the list_get_name callback functions instead of using hardcoded MAX_PATH

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@17049 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Nils Wallménius 2008-04-09 15:25:17 +00:00
parent ae64d2602b
commit 6848961aa5
22 changed files with 146 additions and 102 deletions

View file

@ -40,10 +40,11 @@ struct menu {
static struct menu menus[MAX_MENUS];
static bool inuse[MAX_MENUS] = { false };
static char * menu_get_itemname(int selected_item, void * data, char *buffer)
static char * menu_get_itemname(int selected_item, void * data,
char *buffer, size_t buffer_len)
{
(void)buffer; (void)buffer_len;
struct menu *local_menus=(struct menu *)data;
(void)buffer;
return(local_menus->items[selected_item].desc);
}