[SOLVED] Help understanding crash (exception 0xC0000005)

Started by eri0o, Sat 11/11/2017 19:21:08

Previous topic - Next topic

eri0o

Hello, my game occasionally gives the error below at a specific point:

An exception 0xC0000005 occurred in ACWIN.EXE at EIP = 0x00000000 ; program pointer is +5997, ACI version 3.4.0.16, gtags (72,0)

AGS cannot continue, this exception was fatal. Please note down the number above, remember what you were doing at the time and post the details on the AGS Technical Forum


The part of the game is a change room where I switch the music. The error doesn't happen every time, only sometimes. How do I do diagnostic of these type of errors? It generated a dump but I don't know how to read it. I am using the version: AGS Editor .NET (Build 3.4.0.16), v3.4.0, March 2017.

Thanks

Crimson Wizard

Quote
How do I do diagnostic of these type of errors? It generated a dump but I don't know how to read it.

Normally, if you can read the code, you search for the "program pointer" value, "5997" in this case. There should be a line like "our_eip = 5997" or "SET_EIP(5997)" or "set_our_eip(5997)".

To read crash dump you need:
* Visual studio.
* Your game's exe (or raw engine exe, but that does not work all time).
* Collection of PDB files exactly matching engine version. I am linking these to each AGS release.
* Source code, matching engine version. This may be achieved by taking code from the repository and restoring commit with a tag like "v.3.4.0.16".

These crash dumps that AGS writes are "minidumps" that include call stack, but do not include memory contents, so it may be not trivial to understand what happened, but at least you will be able to see where it happened.


Program pointer 5997 is located in MP3's playback (function MYSTATICMP3::poll in Engine\media\audio\clip_mystaticmp3.cpp)

eri0o

Thanks CW! I changed the way I deal with the music in the room transition and it appears to solve the problem, but now I have a different problem, will post in a different thread. :]

Crimson Wizard

Quote from: eri0o on Sat 11/11/2017 19:57:06
Thanks CW! I changed the way I deal with the music in the room transition and it appears to solve the problem, but now I have a different problem, will post in a different thread. :]
Could you post some details (what did you have and what did you change) in case someone else get same error? This information may also help in case any developer will be looking to fix this crash.

eri0o

I have no idea why, but the problem was when I did audioChannel.TweenVolume and then played a different the audioClip being in that audioChannel - that was before playing a different audio clip. I needed to switch the audioclip first and then switch the audioChannel.

SMF spam blocked by CleanTalk