Skip to content

Commit

Permalink
fix: modelHasNotes stack overflow in some non-English translations (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
philmoz authored and pfeerick committed Mar 28, 2024
1 parent 58b8cb3 commit 23769c5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion radio/src/gui/gui_common.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1078,7 +1078,7 @@ bool isTrainerModeAvailable(int mode)

bool modelHasNotes()
{
char filename[sizeof(MODELS_PATH)+1+sizeof(g_model.header.name)+sizeof(TEXT_EXT)] = MODELS_PATH "/";
char filename[sizeof(MODELS_PATH)+1+LEN_MODEL_NAME*3+sizeof(TEXT_EXT)] = MODELS_PATH "/";
char *buf = strcat_currentmodelname(&filename[sizeof(MODELS_PATH)], 0);
strcpy(buf, TEXT_EXT);
if (isFileAvailable(filename)) {
Expand Down

0 comments on commit 23769c5

Please sign in to comment.