Modify ScummEngine::getResourceSize to assert if called on a missing resource, instead of trying to read from high memory
svn-id: r25806
This commit is contained in:
parent
a63a71eb78
commit
f1f28b61a9
1 changed files with 1 additions and 0 deletions
|
@ -721,6 +721,7 @@ int ScummEngine::getResourceRoomNr(int type, int idx) {
|
|||
|
||||
int ScummEngine::getResourceSize(int type, int idx) {
|
||||
byte *ptr = getResourceAddress(type, idx);
|
||||
assert(ptr);
|
||||
MemBlkHeader *hdr = (MemBlkHeader *)(ptr - sizeof(MemBlkHeader));
|
||||
|
||||
return hdr->size;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue