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 5339

Summary: Minor memory leak in SDL_x11events.c
Product: SDL Reporter: wcodelyokoyt
Component: videoAssignee: Sam Lantinga <slouken>
Status: RESOLVED FIXED QA Contact: Sam Lantinga <slouken>
Severity: trivial    
Priority: P2    
Version: 2.0.13   
Hardware: All   
OS: Linux   

Description wcodelyokoyt 2020-11-03 21:02:33 UTC
The atom name that X11_GetAtomName() returns never gets freed, which result in a minor memory leak (14 bytes?) every time the user drops a file on a window.
You can see the line in question here:
https://github.com/spurious/SDL-mirror/blob/6b6170caf69b4189c9a9d14fca96e97f09bbcc41/src/video/x11/SDL_x11events.c#L1350

Fix: call XFree on name after the while loop.
Comment 1 Sam Lantinga 2020-11-09 07:40:38 UTC
Fixed, thanks!
https://hg.libsdl.org/SDL/rev/f89630148f39