diff --git a/source/Windows/Win32Frame.cpp b/source/Windows/Win32Frame.cpp index 31528198..6d8de3b4 100644 --- a/source/Windows/Win32Frame.cpp +++ b/source/Windows/Win32Frame.cpp @@ -47,7 +47,7 @@ Win32Frame::Win32Frame() buttonx = BUTTONX; buttony = BUTTONY; g_hFrameDC = (HDC)0; - framerect = { 0,0,0,0 }; + memset(&framerect, 0, sizeof(framerect)); helpquit = 0; smallfont = (HFONT)0; @@ -61,6 +61,10 @@ Win32Frame::Win32Frame() g_nTrackDrive2 = -1; g_nSectorDrive1 = -1; g_nSectorDrive2 = -1; + strcpy_s(g_sTrackDrive1, sizeof(g_sTrackDrive1), "??"); + strcpy_s(g_sTrackDrive2, sizeof(g_sTrackDrive1), "??"); + strcpy_s(g_sSectorDrive1, sizeof(g_sTrackDrive1), "??"); + strcpy_s(g_sSectorDrive2, sizeof(g_sTrackDrive1), "??"); g_eStatusDrive1 = DISK_STATUS_OFF; g_eStatusDrive2 = DISK_STATUS_OFF; diff --git a/source/Windows/Win32Frame.h b/source/Windows/Win32Frame.h index 75ec7306..0328ef35 100644 --- a/source/Windows/Win32Frame.h +++ b/source/Windows/Win32Frame.h @@ -173,10 +173,10 @@ private: int g_nTrackDrive2; int g_nSectorDrive1; int g_nSectorDrive2; - TCHAR g_sTrackDrive1[8] = TEXT("??"); - TCHAR g_sTrackDrive2[8] = TEXT("??"); - TCHAR g_sSectorDrive1[8] = TEXT("??"); - TCHAR g_sSectorDrive2[8] = TEXT("??"); + TCHAR g_sTrackDrive1[8]; + TCHAR g_sTrackDrive2[8]; + TCHAR g_sSectorDrive1[8]; + TCHAR g_sSectorDrive2[8]; Disk_Status_e g_eStatusDrive1; Disk_Status_e g_eStatusDrive2;