From eb3f1462b880fe3770e49c0e3a0478e0151b01cc Mon Sep 17 00:00:00 2001 From: Cameron Gutman Date: Fri, 12 Nov 2021 18:26:15 -0600 Subject: [PATCH] x11: Fix memory leak in X11_CreatePixmapCursor() --- src/video/x11/SDL_x11mouse.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/video/x11/SDL_x11mouse.c b/src/video/x11/SDL_x11mouse.c index 50983df19..3d0a74772 100644 --- a/src/video/x11/SDL_x11mouse.c +++ b/src/video/x11/SDL_x11mouse.c @@ -195,6 +195,8 @@ X11_CreatePixmapCursor(SDL_Surface * surface, int hot_x, int hot_y) &fg, &bg, hot_x, hot_y); X11_XFreePixmap(display, data_pixmap); X11_XFreePixmap(display, mask_pixmap); + SDL_free(data_bits); + SDL_free(mask_bits); return cursor; }