From c0d21ee12600d87b5f5120a565919e488bfd6e91 Mon Sep 17 00:00:00 2001 From: disinvite Date: Wed, 29 May 2024 16:37:58 -0400 Subject: [PATCH] Modern compiler fix --- LEGO1/omni/src/video/mxpalette.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/LEGO1/omni/src/video/mxpalette.cpp b/LEGO1/omni/src/video/mxpalette.cpp index d7173886..7738a198 100644 --- a/LEGO1/omni/src/video/mxpalette.cpp +++ b/LEGO1/omni/src/video/mxpalette.cpp @@ -114,7 +114,8 @@ MxPalette::~MxPalette() LPDIRECTDRAWPALETTE MxPalette::CreateNativePalette() { if (m_palette == NULL) { - for (MxS32 i = 0; i < 10; i++) { + MxS32 i; + for (i = 0; i < 10; i++) { m_entries[i].peFlags = D3DPAL_RESERVED; } @@ -179,7 +180,8 @@ MxResult MxPalette::SetEntries(LPPALETTEENTRY p_entries) MxResult status = SUCCESS; if (m_palette) { - for (MxS32 i = 0; i < 10; i++) { + MxS32 i; + for (i = 0; i < 10; i++) { m_entries[i].peFlags = D3DPAL_RESERVED; }