diff --git a/radio/src/eeprom_rlc.cpp b/radio/src/eeprom_rlc.cpp index dfa968e8d..3c42a6712 100644 --- a/radio/src/eeprom_rlc.cpp +++ b/radio/src/eeprom_rlc.cpp @@ -582,7 +582,7 @@ const pm_char * eeBackupModel(uint8_t i_fileSrc) len = i+1; if (len) { if (buf[i]) - buf[i] = idx2char(buf[i]); + buf[i] = idx2char(buf[i]); else buf[i] = '_'; } @@ -597,6 +597,11 @@ const pm_char * eeBackupModel(uint8_t i_fileSrc) len = sizeof(MODELS_PATH) + PSIZE(TR_MODEL) + 2; } +#if defined(RTCLOCK) + char * tmp = strAppendDate(&buf[len], true); + len = tmp - buf; +#endif + strcpy_P(&buf[len], STR_MODELS_EXT); #ifdef SIMU diff --git a/radio/src/opentx.h b/radio/src/opentx.h index a43085a59..4e13a2fbe 100644 --- a/radio/src/opentx.h +++ b/radio/src/opentx.h @@ -1513,7 +1513,7 @@ union ReusableBuffer uint16_t eepromfree; #if defined(SDCARD) char menu_bss[MENU_MAX_LINES][MENU_LINE_LENGTH]; - char mainname[42]; // because reused for SD backup / restore + char mainname[sizeof(menu_bss)]; // because reused for SD backup / restore #else char mainname[LEN_MODEL_NAME]; #endif