[Scummvm-git-logs] scummvm master -> 835759170717fbb259e59475388c579e5abe3132

Strangerke noreply at scummvm.org
Mon Jun 9 09:33:46 UTC 2025


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

Summary:
8357591707 M4: Add safeguard in CrunchAnim8 (Coverity 1532964)


Commit: 835759170717fbb259e59475388c579e5abe3132
    https://github.com/scummvm/scummvm/commit/835759170717fbb259e59475388c579e5abe3132
Author: Strangerke (arnaud.boutonne at gmail.com)
Date: 2025-06-09T10:33:30+01:00

Commit Message:
M4: Add safeguard in CrunchAnim8 (Coverity 1532964)

Changed paths:
    engines/m4/wscript/ws_cruncher.cpp


diff --git a/engines/m4/wscript/ws_cruncher.cpp b/engines/m4/wscript/ws_cruncher.cpp
index a0dd5a74859..3706e4d61cf 100644
--- a/engines/m4/wscript/ws_cruncher.cpp
+++ b/engines/m4/wscript/ws_cruncher.cpp
@@ -1373,7 +1373,7 @@ bool CrunchAnim8(Anim8 *myAnim8) {
 		dbg_SetCurrMachInstr(myAnim8->myMachine, myAnim8->pcOffset, true);
 
 		const int32 myInstruction = ws_PreProcessPcode(&myPC, myAnim8);
-		if (myInstruction < 0) {
+		if (myInstruction < 0 || myInstruction > 39) {
 			ws_Error(myAnim8->myMachine, ERR_SEQU, 0x025c, nullptr);
 		}
 




More information about the Scummvm-git-logs mailing list