Jump to content
  • Advertisement
Sign in to follow this  

Mix_FreeMusic() blocks forever on some machines

This topic is 3938 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I've been having a strange bit of trouble with SDL Mixer's music functions lately. Essentially, I have set up a very basic music playing scheme in a program, and it works on almost every computer I've sent it to -- except one or two. For them, any calls to Mix_FreeMusic() end up blocking indefinitely, and they have to terminate the program manually. So, I have it so that when the user starts a new game, a song is started, and it just loops. If the user starts another new game, or sends a console command to start another song, the current song is halted and freed before starting the new song, and this is where it is constantly hanging, right when Mix_FreeMusic() is called. I have not been able to find any useful information about why this could be happening. It is not being called from within a callback function, as SDL_Mixer warns about. The documentation says it may block until the song has faded out, but I threw in code to check if it was set to fade (it wasn't), and then code to force it to fade in 1 ms (no change in behavior). I'm tempted to write this off as just a problem with those computers, but that might just be too optimistic. I really don't want to switch to another audio api, but I may have to. Also, I don't have any additional information about their computers, because they are in Utah and I am still trying to get more debugging information from them. Any ideas?

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!