0
0

I’m getting an access violation error just after I call FMOD::System::release(). Is there a known bug with the current release of the FMOD Ex API?

This is the essence of my initialization code for setting up my FMOD::System object –

[code:c3m96p30]
FMOD::System *m_FmodSystem;

FMOD::System_Create(&m_FmodSystem);

m_FmodSystem->init(100, FMOD_INIT_NORMAL, 0);

// Load and play some sounds

m_FmodSystem->release();
[/code:c3m96p30]

I can’t understand what’s causing an access violation. Leaving out the release() call altogether means everything quits nice and clean!

Any help would be great.

  • You must to post comments
0
0

Do you have any other things that should be released <prior to> as well? groups, occlusion geometry, etc.

It’s not a clean exits not to call system release but on Windows it’s not a big deal. Better have a clean exit. But it’s best for you to have a seamingly clean exit (to the eyes of your users), not calling release.

There has to be something going on in your code somewhere. I have no problems myself.

  • You must to post comments
0
0

you should use FMOD_System_Close before FMOD_System_Release…
if you close/release immediatelly after create/init, I recommend to use sleep(1) (kernel api) before closing/releasing

  • You must to post comments
0
0

This should not be causing an access violation please send us a minimal reproduction of the error to support@fmod.org and we can take a look.

You don’t have to close before release, release will call close internally if it hasn’t already been called.

Every OS should reclaim all the memory allocated by a process when it closes, but it’s still good practice to clean up after yourself.

-Pete

  • You must to post comments
Showing 3 results
Your Answer

Please first to submit.