Crash with USB headset

(uber_jorgen) #1

Our users have been reporting crashes when playing our game with a USB headset. Specifically, a headset that reports itself as “Afterglow Universal Wireless Gaming Headset” seems to cause trouble.

They are hypothesizing that it’s related to remove/add events for the audio device, but we haven’t investigated it at our office.

This thread on our community bugtracker talks about the problem, along with links to user threads on various forums detailing the problems they’re having:

In our crash reporting system we see a handful of crashes that are entirely inside fmodex64.dll, and that might be related, but we do not have symbols for this DLL, so I cannot really say.

(Nicholas Wilcox) #2

As a licensed customer you can download the source and build the libraries locally so you can have the corresponding PDB. Email if you don’t have a customer account setup yet.

I just did a quick test on the latest version in the 4.44 branch and device removal doesn’t lead to any crashes. What specific version of FMOD Ex are you using?

Do you have a separate voice-chat FMOD system object and game-audio system object? Do you have a system callback function registered?

(uber_jorgen) #3

We’re using 4.44.35, and we only have one system object (created through an FMOD::EventSystem.) It’s possible these issues are isolated to that specific headset.

I’ll investigate getting a local build so we can have symbols.

(uber_jorgen) #4

We’ve now finally gotten a crash where we have the symbols. This is the call stack. It seems to be a common problem for users with these headsets, not sure what in particular about it is causing the problem. Here’s the crash info:

We haven’t had reports from other users with FMOD crashes, so it seems to be specific to this hardware.

(Nicholas Wilcox) #5

This crash is pretty far away from any device handling code. The only way I can see a specific device causing this crash would be if it was triggering a memory leak. Are you checking the return code from all FMOD functions? Ignoring a FMOD_ERR_MEMORY result and calling another function can cause random crashes. You could also hook into the out-of-memory callback.