[Scummvm-git-logs] scummvm branch-2-5 -> 30147ee87309a059784cc6a2e764f2285a59f948

dreammaster dreammaster at scummvm.org
Sun Nov 7 22:48:51 UTC 2021


This automated email contains information about 2 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
8749a25817 XEEN: fix out-of-bounds accesses
30147ee873 XEEN: Fix end address of spells grid fill


Commit: 8749a258177eb38697415bf83b10816b290683ee
    https://github.com/scummvm/scummvm/commit/8749a258177eb38697415bf83b10816b290683ee
Author: Benoit Pierre (benoit.pierre at gmail.com)
Date: 2021-11-07T14:48:39-08:00

Commit Message:
XEEN: fix out-of-bounds accesses

Changed paths:
    engines/xeen/combat.cpp


diff --git a/engines/xeen/combat.cpp b/engines/xeen/combat.cpp
index 4d655e0234..b02c6aa41b 100644
--- a/engines/xeen/combat.cpp
+++ b/engines/xeen/combat.cpp
@@ -94,7 +94,7 @@ static const int MONSTER_ITEM_RANGES[6] = { 10, 20, 50, 100, 100, 100 };
 Combat::Combat(XeenEngine *vm): _vm(vm), _missVoc("miss.voc") {
 	Common::fill(&_attackMonsters[0], &_attackMonsters[26], 0);
 	Common::fill(&_shootingRow[0], &_shootingRow[MAX_PARTY_COUNT], 0);
-	Common::fill(&_monsterMap[0][0], &_monsterMap[32][32], 0);
+	Common::fill(&_monsterMap[0][0], &_monsterMap[31][32], 0);
 	Common::fill(&_monsterMoved[0], &_monsterMoved[MAX_NUM_MONSTERS], false);
 	Common::fill(&_rangeAttacking[0], &_rangeAttacking[MAX_NUM_MONSTERS], false);
 	Common::fill(&_gmonHit[0], &_gmonHit[36], 0);
@@ -452,7 +452,7 @@ void Combat::moveMonsters() {
 	if (intf._charsShooting)
 		return;
 
-	Common::fill(&_monsterMap[0][0], &_monsterMap[32][32], 0);
+	Common::fill(&_monsterMap[0][0], &_monsterMap[31][32], 0);
 	Common::fill(&_monsterMoved[0], &_monsterMoved[MAX_NUM_MONSTERS], false);
 	Common::fill(&_rangeAttacking[0], &_rangeAttacking[MAX_NUM_MONSTERS], false);
 	Common::fill(&_gmonHit[0], &_gmonHit[36], -1);


Commit: 30147ee87309a059784cc6a2e764f2285a59f948
    https://github.com/scummvm/scummvm/commit/30147ee87309a059784cc6a2e764f2285a59f948
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2021-11-07T14:48:39-08:00

Commit Message:
XEEN: Fix end address of spells grid fill

Changed paths:
    engines/xeen/dialogs/dialogs_spells.cpp


diff --git a/engines/xeen/dialogs/dialogs_spells.cpp b/engines/xeen/dialogs/dialogs_spells.cpp
index 4f6819e724..6998a93858 100644
--- a/engines/xeen/dialogs/dialogs_spells.cpp
+++ b/engines/xeen/dialogs/dialogs_spells.cpp
@@ -1027,7 +1027,7 @@ void DetectMonsters::execute() {
 	int grid[7][7];
 
 	SpriteResource sprites(ccNum ? "detectmn.icn" : "detctmon.icn");
-	Common::fill(&grid[0][0], &grid[6][6], 0);
+	Common::fill(&grid[0][0], &grid[6][7], 0);
 
 	w.open();
 	w.writeString(Res.DETECT_MONSTERS);




More information about the Scummvm-git-logs mailing list