From 3ef080299336e1e1665deceea5539c34d4093024 Mon Sep 17 00:00:00 2001 From: Colin Snover Date: Thu, 24 Aug 2017 21:46:16 -0500 Subject: TITANIC: Fix buffer overflow when getting first class upgrade --- engines/titanic/gfx/text_control.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'engines/titanic/gfx') diff --git a/engines/titanic/gfx/text_control.cpp b/engines/titanic/gfx/text_control.cpp index d1d2e1c530..b0d1cd9ab2 100644 --- a/engines/titanic/gfx/text_control.cpp +++ b/engines/titanic/gfx/text_control.cpp @@ -263,7 +263,7 @@ void CTextControl::remapColors(uint count, uint *srcColors, uint *destColors) { for (uint index = 0; index < count; ++index) { if (color == srcColors[index]) { // Found a match, so replace the color - setLineColor(lineNum, destColors[lineNum]); + setLineColor(lineNum, destColors[index]); break; } } -- cgit v1.2.3