Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Touch events cause segfault on Android #1537

Closed
SDLBugzilla opened this issue Feb 10, 2021 · 0 comments
Closed

Touch events cause segfault on Android #1537

SDLBugzilla opened this issue Feb 10, 2021 · 0 comments

Comments

@SDLBugzilla
Copy link
Collaborator

This bug report was migrated from our old Bugzilla tracker.

These attachments are available in the static archive:

Reported in version: HG 2.0
Reported for operating system, platform: Android (All), Other

Comments on the original bug report:

On 2014-06-27 15:39:40 +0000, Alvin wrote:

Created attachment 1714
Passes Android_Window to the mouse-related functions rather than NULL.

Touch (mouse) events on Android result in a segfault.

From what I can determine, the bug was introduced in be64f5daf64b (Implemented SDL_Capture()). In src/events/SDL_mouse.c, in SDL_PrivateSendMouseMotion(), at line 251, the 'window' pointer is accessed. On Android, the 'window' argument is NULL. (see Android_OnTouch() e.g. line 89 - call to SDL_SendMouseMotion).

Attached is a patch for Android_OnTouch() that passing the 'Android_Window' global variable.

Tested on Android 4.0.4.

On 2014-06-28 15:50:52 +0000, Gabriel Jacobo wrote:

Fixed, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant