Fix startup crash from over-long "Speak Hylian" stat name (#6995)

itemTimestampDisplayName rows are char[24], sized for the 23-char column the
table uses. #6978 corrected "SpeakHylian:" to "Speak Hylian:" but kept the
original padding, making the string 24 chars + NUL = 25 bytes. That overflows
the buffer, so the strcpy in SetupDisplayNames aborts (__strcpy_chk) at GUI
init on any _FORTIFY_SOURCE build, crashing before the main menu. Drop one
trailing space to restore the 23-char column.

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
David Racine
2026-07-30 10:11:48 -04:00
committed by GitHub
parent 2c5762a0f2
commit c7d72c0cdb
+1 -1
View File
@@ -897,7 +897,7 @@ void SetupDisplayNames() {
strcpy(itemTimestampDisplayName[TIMESTAMP_FOUND_SPEAK_DEKU], "Speak Deku: ");
strcpy(itemTimestampDisplayName[TIMESTAMP_FOUND_SPEAK_GERUDO], "Speak Gerudo: ");
strcpy(itemTimestampDisplayName[TIMESTAMP_FOUND_SPEAK_GORON], "Speak Goron: ");
strcpy(itemTimestampDisplayName[TIMESTAMP_FOUND_SPEAK_HYLIAN], "Speak Hylian: ");
strcpy(itemTimestampDisplayName[TIMESTAMP_FOUND_SPEAK_HYLIAN], "Speak Hylian: ");
strcpy(itemTimestampDisplayName[TIMESTAMP_FOUND_SPEAK_KOKIRI], "Speak Kokiri: ");
strcpy(itemTimestampDisplayName[TIMESTAMP_FOUND_SPEAK_ZORA], "Speak Zora: ");
strcpy(itemTimestampDisplayName[TIMESTAMP_FOUND_DMC_BEAN_SOUL], "DMC Bean Soul: ");