[Scummvm-git-logs] scummvm master -> b12feb2ae96cfc61af8f65b72e9bf01cb3a81fc0
NMIError
noreply at scummvm.org
Sun Jun 5 12:33:42 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:
b12feb2ae9 AGOS: Add Simon 1 invalid AdLib errors
Commit: b12feb2ae96cfc61af8f65b72e9bf01cb3a81fc0
https://github.com/scummvm/scummvm/commit/b12feb2ae96cfc61af8f65b72e9bf01cb3a81fc0
Author: Coen Rampen (crampen at gmail.com)
Date: 2022-06-05T14:31:48+02:00
Commit Message:
AGOS: Add Simon 1 invalid AdLib errors
This adds error messages in case the Simon 1 AdLib instrument bank file is
missing or invalid.
Changed paths:
engines/agos/drivers/simon1/adlib.cpp
diff --git a/engines/agos/drivers/simon1/adlib.cpp b/engines/agos/drivers/simon1/adlib.cpp
index 1f88cd4be8a..2022f7216a2 100644
--- a/engines/agos/drivers/simon1/adlib.cpp
+++ b/engines/agos/drivers/simon1/adlib.cpp
@@ -304,19 +304,19 @@ MidiDriver_Multisource *createMidiDriverSimon1AdLib(const char *instrumentFilena
Common::File ibk;
if (!ibk.open(instrumentFilename)) {
- return nullptr;
+ error("MidiDriver_Simon1_AdLib::createMidiDriverSimon1AdLib - Could not find AdLib instrument bank file %s", instrumentFilename);
}
// Check for the expected FourCC (IBK\x1A)
if (ibk.readUint32BE() != 0x49424b1a) {
- return nullptr;
+ error("MidiDriver_Simon1_AdLib::createMidiDriverSimon1AdLib - Invalid AdLib instrument bank file %s", instrumentFilename);
}
byte *instrumentData = new byte[128 * 16];
if (ibk.read(instrumentData, 128 * 16) != 128 * 16) {
// Failed to read the expected amount of data.
delete[] instrumentData;
- return nullptr;
+ error("MidiDriver_Simon1_AdLib::createMidiDriverSimon1AdLib - Unexpected AdLib instrument bank file %s size", instrumentFilename);
}
MidiDriver_Simon1_AdLib *driver = new MidiDriver_Simon1_AdLib(oplType, instrumentData);
More information about the Scummvm-git-logs
mailing list