We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 5426

Summary: Sudden stop in game while forward key is still being pressed
Product: SDL Reporter: maxi
Component: videoAssignee: Ozkan Sezer <sezeroz>
Status: RESOLVED FIXED QA Contact: Sam Lantinga <slouken>
Severity: normal    
Priority: P2 CC: sezeroz
Version: 1.2.15   
Hardware: x86_64   
OS: Linux   
Attachments: Backport of [2] and [3] to libsdl1.2 which fixed the issue described in this bug report

Description maxi 2020-12-30 18:20:37 UTC
Created attachment 4618 [details]
Backport of [2] and [3] to libsdl1.2 which fixed the issue described in this bug report

Since some time I stated to observe an annoying bug with the forward movement suddenly stopping while I was still pressing the corresponding key for the forward movement. Releasing and pressing the key again continued the movement. I observed this in the game "Unreal Tournament 2004", but other software is probably also affected. The stop basically happens after a few minutues of pressing the key, through the time needed to reproduce the issue is not constant.
While investigating the issue I found it started with a commit [1] in the Xorg xserver. Digging deeper into the code I found two commits [2] [3] in libsdl2 which looked like they would also fix the issue in libsdl1.2. I backported these two commits to the libsdl1.2 in Debian and can confirm that the bug got fixed by this. I am attaching the patch for my backporting to this bug report.

As I've seen there is still development in the libsdl1.2 branch, I think this fix also should be included there.

[1] https://cgit.freedesktop.org/xorg/xserver/commit/?id=c67f2eac56518163981af59f5accb7c79bc00f6a
[2] https://hg.libsdl.org/SDL/rev/a1c4c17410e8
[3] https://hg.libsdl.org/SDL/rev/764129077d18
Comment 1 Ozkan Sezer 2020-12-30 19:20:03 UTC
Ryan, Sam:  This looks good to me.  OK to apply to SDL-1.2 branch?
Comment 2 Sam Lantinga 2020-12-30 19:40:05 UTC
Yep
Comment 3 Ozkan Sezer 2020-12-30 20:00:58 UTC
OK, patch applied as https://hg.libsdl.org/SDL/rev/336bcaa9432c
Thanks.  Closing as fixed.