summaryrefslogtreecommitdiff
path: root/apps/menu.c
diff options
context:
space:
mode:
authorRafaël Carré <rafael.carre@gmail.com>2010-09-21 09:04:22 +0000
committerRafaël Carré <rafael.carre@gmail.com>2010-09-21 09:04:22 +0000
commit53ac2ca831905030421b5408bbc4c685eed644d4 (patch)
treef167056d1bffabddbc8a1c9f90ef615a42f4ebf9 /apps/menu.c
parent7d9df4847882f5930e3dc6a6a89d05021c9bf493 (diff)
do_setting_from_menu(): remove write-only variables
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28136 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/menu.c')
-rw-r--r--apps/menu.c13
1 files changed, 1 insertions, 12 deletions
diff --git a/apps/menu.c b/apps/menu.c
index 5b8b121b1a..8142f9938e 100644
--- a/apps/menu.c
+++ b/apps/menu.c
@@ -283,22 +283,11 @@ static int talk_menu_item(int selected_item, void *data)
void do_setting_from_menu(const struct menu_item_ex *temp,
struct viewport parent[NB_SCREENS])
{
- int setting_id, oldval;
+ int setting_id;
const struct settings_list *setting =
find_setting(temp->variable, &setting_id);
char *title;
char padded_title[MAX_PATH];
- int var_type = setting->flags&F_T_MASK;
- if (var_type == F_T_INT || var_type == F_T_UINT)
- {
- oldval = *(int*)setting->setting;
- }
- else if (var_type == F_T_BOOL)
- {
- oldval = *(bool*)setting->setting;
- }
- else
- oldval = 0;
if ((temp->flags&MENU_TYPE_MASK) == MT_SETTING_W_TEXT)
title = temp->callback_and_desc->desc;
else