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

Fix the potential memcpy to itself, in case SDL_numGestureTouches is zero #14

Closed
wants to merge 1 commit into from

Conversation

dmikushin
Copy link

==389919== Thread 1:
==389919== Source and destination overlap in memcpy(0x732abf0, 0x732abf0, 8240)
==389919== at 0x4C32513: memcpy@@GLIBC_2.14 (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==389919== by 0x460C2C: SDL_memcpy_REAL (SDL_string.c:321)
==389919== by 0x440132: SDL_GestureDelTouch (SDL_gesture.c:490)
==389919== by 0x444EE7: SDL_DelTouch (SDL_touch.c:460)
==389919== by 0x444F21: SDL_TouchQuit (SDL_touch.c:469)
==389919== by 0x477761: SDL_VideoQuit_REAL (SDL_video.c:2955)
==389919== by 0x58581D: SDL_QuitSubSystem_REAL (SDL.c:370)
==389919== by 0x5859C6: SDL_Quit_REAL (SDL.c:435)
==389919== by 0x432973: SDL_Quit (SDL_dynapi_procs.h:89)

@okuoku
Copy link

okuoku commented Jan 10, 2021

@dmikushin : Good catch. I guess it's definitely a bug, but here is just a mirror.

Please file against official Bugzilla https://bugzilla.libsdl.org/ to patch official repository.

@dmikushin
Copy link
Author

Dear @okuoku could you please kindly help me to upsteam this to the libsdl bugzilla. I fully understand and respect developers' preference, but filling a PR here is the most effort I can contribute.

@okuoku
Copy link

okuoku commented Jan 10, 2021

@dmikushin : Would you mind me to file issue to the bugzilla instead of you? If so, I'll take care of this.

@okuoku
Copy link

okuoku commented Jan 10, 2021

filed: https://bugzilla.libsdl.org/show_bug.cgi?id=5456

@okuoku
Copy link

okuoku commented Jan 11, 2021

Merged as 0925e77

https://hg.libsdl.org/SDL/rev/17d911637a65

(Please close this PR once you've confirmed.)

@spurious
Copy link
Owner

This was moved to libsdl-org/SDL#3977

@spurious spurious closed this Feb 11, 2021
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

Successfully merging this pull request may close these issues.

3 participants