Opened 7 years ago

Closed 7 years ago

#10188 closed defect (fixed)

SCI: Torin RU: Access violation on startup

Reported by: CrazyMax Owned by: csnover
Priority: normal Component: Engine: SCI
Version: Keywords: sci32
Cc: Game: Torin's Passage

Description

Win32 ScummVM Daily Snapshot from from https://www.scummvm.org/downloads/:
ScummVM 1.10.0git4756-g902b191266 (Sep 7 2017 13:10:23)
Features compiled in: TAINTED Vorbis FLAC MP3 RGB zLib MPEG2 FluidSynth Theora AAC FreeType2 JPEG PNG

User picked target 'torin-cd-win-ru' (gameid 'sci')...
  Looking for a plugin supporting this gameid... SCI [SCI0, SCI01, SCI10, SCI11, SCI32]
  Starting 'Sierra SCI Game'
WARNING: Resource sync36.38140(9, 4, 70, 44) from RESSCI.000 points beyond end of RESOURCE.AUD (2483117822 + 64000 > 210583510)!
WARNING: Resource audio36.38140(9, 4, 70, 44) from RESSCI.000 points beyond end of RESOURCE.AUD (2483181822 >= 210583510)!
WARNING: Resource sync36.38140(122, 1, 2, 42) from RESSCI.000 points beyond end of RESOURCE.AUD (4182770235 + 516 > 210583510)!
WARNING: Resource audio36.38140(122, 1, 2, 42) from RESSCI.000 points beyond end of RESOURCE.AUD (4182770751 >= 210583510)!
WARNING: Resource sync36.38140(180, 61, 0, 2) from RESSCI.000 points beyond end of RESOURCE.AUD (1761644638 + 80 > 210583510)!
WARNING: Resource audio36.38140(180, 61, 0, 2) from RESSCI.000 points beyond end of RESOURCE.AUD (1761644718 >= 210583510)!
WARNING: Resource sync36.38140(42, 1, 1, 9) from RESSCI.000 points beyond end of RESOURCE.AUD (2299511809 + 65283 > 210583510)!
WARNING: Resource audio36.38140(42, 1, 1, 9) from RESSCI.000 points beyond end of RESOURCE.AUD (2299577092 >= 210583510)!
Access violation reading map.38140: 98 + 2 > 99 (abs: 98 + 2 > 99)!

in earlier versions it worked fine

Attachments (1)

38140.map (101 bytes ) - added by CrazyMax 7 years ago.
Torin's Passage RU

Download all attachments as: .zip

Change History (7)

comment:1 by csnover, 7 years ago

Keywords: sci32 added
Summary: SCI32: Crash on load Torin's Passage (Russian)SCI: Torin RU: Access violation on startup

Thanks for your report! In earlier versions of ScummVM, the parsing of this map may not have actually been working fine; without error checking, instead of these warnings, you probably would’ve just ended up with bad audio at some point in the game, or a random crash at startup, or a random crash at a point during the game.

Looking at the integrity checking output, it seems like the audio map parser heuristic is failing and thinks this audio map is a type with entry size 12. This would be triggered if the last byte of the final offset in the map was 0xFF, but this would mean the final offset was over 16MB away from the previous sample, which seems odd.

Could you please double-check that your game files have not been corrupted by checking against an original source, and if the problem persists, run diskdump map 38140 in the debugger that appears when the access violation occurs and attach the map.38140 file that is generated to this ticket? (It should be found in the directory where the ScummVM executable lives.) Thanks!

comment:2 by csnover, 7 years ago

Owner: set to CrazyMax
Resolution: worksforme
Status: newpending

comment:3 by CrazyMax, 7 years ago

i cant run debug a command "diskdump map 38140" because scummvm crash before debugger init.
i'm trying run with --debug-flags=onstartup in command line, same "Access violation" before the debugger init.

crash in sci.cpp at line 810 ("source->scanSource(this);"):

void ResourceManager::scanNewSources() {
        _hasBadResources = false;

        for (Common::List<ResourceSource *>::iterator it = _sources.begin(); it != _sources.end(); ++it) {
                ResourceSource *source = *it;

                if (!source->_scanned) {
                        source->_scanned = true;
                        source->scanSource(this);
                }
        }

        // The warning dialog is shown here instead of someplace more obvious like
        // SciEngine::run because resource sources can be dynamically added
        // (e.g. KQ5 via kDoAudio, MGDX via kSetLanguage), and users really should
        // be warned of bad resources in this situation (KQ Collection 1997 has a
        // bad copy of KQ5 on CD 1; the working copy is on CD 2)
        if (!_detectionMode && _hasBadResources) {
                showScummVMDialog(_("Missing or corrupt game resources have been detected. "
                                                        "Some game features may not work properly. Please check "
                                                        "the console for more information, and verify that your "
                                                        "game files are valid."));
        }
}

comment:4 by csnover, 7 years ago

That is a good point.

In this case, could you please do this:

  1. Download and extract SCI Viewer
  2. Open SCI Viewer GUI\SV.exe
  3. Go to File -> Open dir and choose your Torin directory
  4. Click on Map in the left panel
  5. Find the 38140.map in the right panel
  6. Right-click on 38140.map in the right panel and choose Extract
  7. Save and upload the 31840.map file

Thanks!

by CrazyMax, 7 years ago

Attachment: 38140.map added

Torin's Passage RU

comment:5 by CrazyMax, 7 years ago

Uploaded

comment:6 by csnover, 7 years ago

Owner: changed from CrazyMax to csnover
Resolution: worksformefixed
Status: pendingclosed

Thanks for your report! This audio map had previously been getting silently read incorrectly by ScummVM, so the new error checking did its job and surfaced the problem!

A patch for this issue has been added in 1515bb31a6fa802314836a9904756d7fcc840c69 and will be available in daily builds 1.10.0git-4963 and higher.

Note: See TracTickets for help on using tickets.