[Scummvm-git-logs] scummvm master -> 3c5f17dca88287796ddce2988b356b514c0e9780

sev- sev at scummvm.org
Mon Aug 10 08:54:53 UTC 2020


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:
37776d78c6 DIRECTOR: LINGO: Added sanity check
3c5f17dca8 AUDIO: Plug memory leak


Commit: 37776d78c6d9e9f8e99f2a7580c75a58bb26b561
    https://github.com/scummvm/scummvm/commit/37776d78c6d9e9f8e99f2a7580c75a58bb26b561
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-08-10T10:52:45+02:00

Commit Message:
DIRECTOR: LINGO: Added sanity check

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 a7dab11c6e..366a266ffb 100644
--- a/engines/director/lingo/lingo-builtins.cpp
+++ b/engines/director/lingo/lingo-builtins.cpp
@@ -1080,10 +1080,12 @@ void LB::b_getNthFileNameInFolder(int nargs) {
 	Datum r;
 	if (d.exists()) {
 		Common::FSList f;
-		d.getChildren(f, Common::FSNode::kListAll);
-
-		if ((uint)fileNum < f.size())
-			r = Datum(f.operator[](fileNum).getName());
+		if (!d.getChildren(f, Common::FSNode::kListAll)) {
+			warning("Cannot acces directory %s", path.c_str());
+		} else {
+			if ((uint)fileNum < f.size())
+				r = Datum(f.operator[](fileNum).getName());
+		}
 	}
 
 	g_lingo->push(r);


Commit: 3c5f17dca88287796ddce2988b356b514c0e9780
    https://github.com/scummvm/scummvm/commit/3c5f17dca88287796ddce2988b356b514c0e9780
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-08-10T10:54:34+02:00

Commit Message:
AUDIO: Plug memory leak

Changed paths:
    audio/soundfont/vgmcoll.cpp


diff --git a/audio/soundfont/vgmcoll.cpp b/audio/soundfont/vgmcoll.cpp
index 0a893c82bc..647f489e44 100644
--- a/audio/soundfont/vgmcoll.cpp
+++ b/audio/soundfont/vgmcoll.cpp
@@ -172,6 +172,7 @@ SynthFile *VGMColl::CreateSynthFile(VGMInstrSet *theInstrSet) {
 				}
 				if (sampCollNum == finalSampColls.size()) {
 					debug("SampColl does not exist");
+					delete synthfile;
 					return nullptr;
 				}
 				//   now we add the number of samples from the preceding SampColls to the value to




More information about the Scummvm-git-logs mailing list