MAINMENU_HandleEmailChange: Stack[-0x504] aBuffer is WCHAR[256], not char[256]
Both error paths zero-fill aBuffer through the vector constructor iterator CONTAINER_InitializeBuffer (0x00403040) with 0x100 two-byte elements, 512 bytes from EBP-0x500 (Stack[-0x504]). So it is a 256-WCHAR array spanning Stack[-0x504..-0x304). The DB types it char[256], and the rebuild's 512-byte fill overruns the stack by 256 bytes whenever the new e-mail fields differ or match the old one. szNewEmail2 (Stack[-0x404]) shares the upper half of the slot on the other path. Its only access is the WideCharToUTF8 write at 0x004377f2, and nothing reads it (0x00437816..0x00437829 pass only szAccount, szOldEmail and szNewEmail1). Please delete szNewEmail2 to make room, or model the slot as a union.
Changes 1, applied together
Retype variable
win 0x00437730 Stack[-0x504]typechar[256]→WCHAR[256]