From 7a8b0599ff6ec93cb1bf55fd4857e69fa27c32d3 Mon Sep 17 00:00:00 2001 From: alle Date: Sat, 3 Apr 2010 21:28:19 +0000 Subject: [PATCH] No need to call the same function twice git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25458 a1c6a512-1295-4272-9138-f99709370657 --- apps/onplay.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/apps/onplay.c b/apps/onplay.c index 246b8af6b..43c228ca5 100644 --- a/apps/onplay.c +++ b/apps/onplay.c @@ -1326,9 +1326,10 @@ static void set_hotkey(bool is_wps) char **line2_ptr = &line2; const struct text_message message={(const char **)line1_ptr, 1}; const struct text_message yes_message={(const char **)line2_ptr, 1}; - - snprintf(line1, sizeof(line1_buf), str(LANG_SET_HOTKEY_QUESTION), str(this_id)); - snprintf(line2, sizeof(line2_buf), str(LANG_HOTKEY_ASSIGNED), str(this_id)); + char *func_name = str(this_id); + + snprintf(line1, sizeof(line1_buf), str(LANG_SET_HOTKEY_QUESTION), func_name); + snprintf(line2, sizeof(line2_buf), str(LANG_HOTKEY_ASSIGNED), func_name); /* confirm the hotkey setting change */ if(gui_syncyesno_run(&message, &yes_message, NULL)==YESNO_YES) -- 2.11.4.GIT