[A5] dinput random crashes
Something I'm getting a lot is random crashes in dinput8.dll now that I'm using Allegro 5. Should I be using some other version? My game crashes in 5 - 30 seconds from startup and says it happened at dinput8.dll!6ce25738(). Usually (but not always) happens during a keypress. This is a port from Allegro 4; can anyone think of any gotchas I should be watching for? It's not crashing inside al_key_down() and that's all I'm really doing; just populating an array based off that and then using my own code ...
Have you tried running the debug build of Allegro?
I've tried linking with monolith-mt-debug; it's a little more reliable but ultimately no change.
What does the full backtrace look like when it crashes?
There's a kernel32.dll, 5 allegro dll calls and then 10 dinput8.dll calls. It won't show me symbols or source though. It shows this in the disassembly though ...
6CE25738 cmp dword ptr [edx+ecx*4],0FFFFFFFFh
And it's always that address ... dunno how much that helps.
Does it list any allegro functions with line numbers?
Does it crash if you unplug your mouse?
No allegro functions or lines or anything; just references to the dll. I'd try the mouse, but it's started being stubborn about crashing.
EDIT: It's intermittent, so it's tough to say, but it doesn't appear to crash at all with the mouse unplugged. Odd ...
A Google search revealed people with Microsoft Sidewinder mice reporting that dinput8.dll crashes in that same spot, with people then claiming it doesn't work with DirectInput 8. Don't know if your problem is related to something like that or not.
Huh. A Microsoft Sidewinder is what I'm using. Well, that sucks. I guess I'll start looking into that tomorrow but it sounds like there won't be an easy solution.
Thread #606825. Printed from Allegro.cc
I knew I should have just replied with "Unplug your Sidewinder mouse" from the very beginning.