Fix index out of bounds

pull/4970/head
Johan Mattsson 2023-02-20 19:50:06 +01:00 committed by GitHub
parent ad2f0682e7
commit f8132bf17c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -150,7 +150,7 @@ AI_WONT_RETURN void B3DImporter::Fail(const string &str) {
// ------------------------------------------------------------------------------------------------
int B3DImporter::ReadByte() {
if (_pos > _buf.size()) {
if (_pos >= _buf.size()) {
Fail("EOF");
}