[Scummvm-git-logs] scummvm master -> 48cf9477d5339350d06389490b19aca4bb8d5e8f

sev- sev at scummvm.org
Wed Jul 22 11:31:59 UTC 2020


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:
48cf9477d5 DIRECTOR: LINGO: Added sanity check to b_return()


Commit: 48cf9477d5339350d06389490b19aca4bb8d5e8f
    https://github.com/scummvm/scummvm/commit/48cf9477d5339350d06389490b19aca4bb8d5e8f
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-07-22T13:31:31+02:00

Commit Message:
DIRECTOR: LINGO: Added sanity check to b_return()

Changed paths:
    engines/director/lingo/lingo-builtins.cpp


diff --git a/engines/director/lingo/lingo-builtins.cpp b/engines/director/lingo/lingo-builtins.cpp
index 38f041e422..5c84355945 100644
--- a/engines/director/lingo/lingo-builtins.cpp
+++ b/engines/director/lingo/lingo-builtins.cpp
@@ -1326,7 +1326,8 @@ void LB::b_return(int nargs) {
 		g_lingo->pop();
 	}
 
-	g_lingo->_theResult = g_lingo->peek(0);	// Store result for possible reference
+	if (!g_lingo->_stack.empty())
+		g_lingo->_theResult = g_lingo->peek(0);	// Store result for possible reference
 
 	LC::c_procret();
 }




More information about the Scummvm-git-logs mailing list