2.50.1 ZC/ZQ Freezes when Running for Long Duration / Refuses to Accept Input on Win 7

If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

ZC was idling on the save slot selection screen; ZQ, on a dialogue. Post-compile script assignment, or something like that. Probably something with Yes/No several times too. I notice the problem when it idles on dialogue screens, because I'm used to tying k, then c for OK and recompile.

Another thing, is that when alt+tabbing out of focus, and then back, ZC/ZQ act as if you are holding down an arrow key, until you press any key (insert stale joke). The dialogue selector goes mad, moving around in a rapid cycle. This also affects the file selection dialogue in ZC, when opening a quest.

Allegro's keyboard buffer is used from multiple threads, but it's not thread-safe. It has a lock variable, but it's an ordinary int. If that gets messed up, the keyboard is permanently locked, and the GUI stops responding to keyboard input. The buffer isn't accessible outside of Allegro itself, so it can't be corrected when it happens. I've made efforts in the past to reduce the likelihood of it happening, but it's not something we can entirely fix.
I can have it clear the buffer when switching in or out, which should fix the issue with it thinking keys are being held, but that also significantly increases the odds that the keyboard will stop working entirely.