aboutsummaryrefslogtreecommitdiff
path: root/engines/saga/interface.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/saga/interface.cpp')
-rw-r--r--engines/saga/interface.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/engines/saga/interface.cpp b/engines/saga/interface.cpp
index cb09d53762..b08534c7fa 100644
--- a/engines/saga/interface.cpp
+++ b/engines/saga/interface.cpp
@@ -1170,7 +1170,7 @@ void Interface::processStatusTextInput(Common::KeyState keystate) {
_statusTextInputPos--;
_statusTextInputString[_statusTextInputPos] = 0;
default:
- if (_statusTextInputPos >= STATUS_TEXT_INPUT_MAX) {
+ if (_statusTextInputPos > STATUS_TEXT_INPUT_MAX) {
break;
}
if (Common::isAlnum(keystate.ascii) || (keystate.ascii == ' ')) {
@@ -2299,6 +2299,9 @@ void Interface::drawPanelButtonText(InterfacePanel *panel, PanelButton *panelBut
break;
}
if (_vm->getGameId() == GID_ITE) {
+ if (textId > kTextEnterProtectAnswer)
+ error("This should not happen. Please report to ScummVM Team how you achieved this error.");
+
text = _vm->getTextString(textId);
textFont = kKnownFontMedium;
textShadowKnownColor = kKnownColorVerbTextShadow;