Rockbox open source high quality audio player as a Music Player Daemon
mpris rockbox mpd libadwaita audio rust zig deno
2
fork

Configure Feed

Select the types of activity you want to include in your feed.

skin engine - fail gracefully when %Sx is used on non lang id string

CheckWPS doesn't catch errors involving translated strings
Instead of breaking old themes when the langids no long exist
return "<ERR>"

Change-Id: I0d744cd48bb5a27e735fce3f6f740450d1f6a55a

authored by

William Wilgus and committed by
William Wilgus
6fb942d8 e0468074

+3 -2
+1 -1
apps/gui/skin_engine/skin_parser.c
··· 768 768 #ifndef __PCTOOL__ 769 769 i = lang_english_to_id(temp); 770 770 if (i < 0) 771 - return WPS_ERROR_INVALID_PARAM; 771 + i = LANG_LAST_INDEX_IN_ARRAY; 772 772 #endif 773 773 } 774 774 else if (element->params_count > 1)
+2 -1
apps/gui/skin_engine/skin_tokens.c
··· 821 821 return (char*)SKINOFFSETTOPTR(get_skin_buffer(data), token->value.data); 822 822 823 823 case SKIN_TOKEN_TRANSLATEDSTRING: 824 - return (char*)P2STR(ID2P(token->value.i)); 824 + return token->value.i < LANG_LAST_INDEX_IN_ARRAY ? 825 + (char*)P2STR(ID2P(token->value.i)) : "<ERR>"; 825 826 826 827 case SKIN_TOKEN_PLAYLIST_ENTRIES: 827 828 numeric_ret = playlist_amount();