[Scummvm-git-logs] scummvm master -> f567b0f96a801efed58ba5a501905056b2ec1d21

digitall noreply at scummvm.org
Sat Jun 18 13:10:52 UTC 2022


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

Summary:
f567b0f96a AGS: Fix GCC Compiler Warnings


Commit: f567b0f96a801efed58ba5a501905056b2ec1d21
    https://github.com/scummvm/scummvm/commit/f567b0f96a801efed58ba5a501905056b2ec1d21
Author: D G Turner (digitall at scummvm.org)
Date: 2022-06-18T14:10:00+01:00

Commit Message:
AGS: Fix GCC Compiler Warnings

Changed paths:
    engines/ags/engine/ac/draw.cpp
    engines/ags/plugins/ags_plugin.cpp


diff --git a/engines/ags/engine/ac/draw.cpp b/engines/ags/engine/ac/draw.cpp
index 8222d49531f..d28e20a74e3 100644
--- a/engines/ags/engine/ac/draw.cpp
+++ b/engines/ags/engine/ac/draw.cpp
@@ -1725,7 +1725,7 @@ void prepare_room_sprites() {
 
 			if (_G(walkBehindMethod) == DrawAsSeparateSprite) {
 				for (size_t wb = 1 /* 0 is "no area" */;
-					(wb < MAX_WALK_BEHINDS) && (wb < (int)_GP(walkbehindobj).size()); ++wb) {
+					(wb < MAX_WALK_BEHINDS) && (wb < (size_t)_GP(walkbehindobj).size()); ++wb) {
 					const auto &wbobj = _GP(walkbehindobj)[wb];
 					if (wbobj.Ddb) {
 						add_to_sprite_list(wbobj.Ddb, wbobj.Pos.X, wbobj.Pos.Y,
diff --git a/engines/ags/plugins/ags_plugin.cpp b/engines/ags/plugins/ags_plugin.cpp
index 4da04349f8a..fb1d423c91b 100644
--- a/engines/ags/plugins/ags_plugin.cpp
+++ b/engines/ags/plugins/ags_plugin.cpp
@@ -393,7 +393,7 @@ int IAGSEngine::GetNumObjects() {
 	return _G(croom)->numobj;
 }
 AGSObject *IAGSEngine::GetObject(int32 num) {
-	if (num >= _G(croom)->numobj)
+	if (num >= (int32)_G(croom)->numobj)
 		quit("!IAGSEngine::GetObject: invalid object");
 
 	return (AGSObject *)&_G(croom)->obj[num];




More information about the Scummvm-git-logs mailing list