diff options
| author | Eugene Sandulenko | 2016-05-31 13:18:24 +0200 |
|---|---|---|
| committer | Eugene Sandulenko | 2016-05-31 17:12:18 +0200 |
| commit | 459be5e7b248d7cd9f70ffb814d63238c3318796 (patch) | |
| tree | 101915d94cde5f99c0d1c6eb0db205e7df8b0e6c | |
| parent | 678c5eadfa48ebd5079db93d9980cbb67cc39b89 (diff) | |
| download | scummvm-rg350-459be5e7b248d7cd9f70ffb814d63238c3318796.tar.gz scummvm-rg350-459be5e7b248d7cd9f70ffb814d63238c3318796.tar.bz2 scummvm-rg350-459be5e7b248d7cd9f70ffb814d63238c3318796.zip | |
SAGA: Fix potential buffer overrun
| -rw-r--r-- | engines/saga/interface.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/saga/interface.cpp b/engines/saga/interface.cpp index b08534c7fa..9a5e6378b9 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 - 1) { // -1 because of the null termination break; } if (Common::isAlnum(keystate.ascii) || (keystate.ascii == ' ')) { |
