comparison src/video/x11/SDL_x11mouse.c @ 888:07def9d03315

Date: Sun, 28 Mar 2004 16:38:32 +1200 From: Paul Eggleton Subject: [SDL] Possible memory leak in SDL 1.2.7 Taking a look at this function X11_CreateWMCursor and its companion X11_FreeWMCursor (in src/video/x11/SDL_x11mouse.c), I can see that X11_CreateWMCursor is making several calls to XCreatePixmap, but there are no corresponding calls in X11_FreeWMCursor to XFreePixmap.
author Sam Lantinga <slouken@libsdl.org>
date Sun, 16 May 2004 17:40:32 +0000
parents b8d311d90021
children 045f186426e1
comparison
equal deleted inserted replaced
887:b4b64bb88f2f 888:07def9d03315
140 XDestroyImage(mask_image); 140 XDestroyImage(mask_image);
141 141
142 /* Create the cursor */ 142 /* Create the cursor */
143 cursor->x_cursor = XCreatePixmapCursor(SDL_Display, data_pixmap, 143 cursor->x_cursor = XCreatePixmapCursor(SDL_Display, data_pixmap,
144 mask_pixmap, &black, &white, hot_x, hot_y); 144 mask_pixmap, &black, &white, hot_x, hot_y);
145 XFreePixmap(SDL_Display, data_pixmap);
146 XFreePixmap(SDL_Display, mask_pixmap);
145 147
146 /* Release the event thread */ 148 /* Release the event thread */
147 XSync(SDL_Display, False); 149 XSync(SDL_Display, False);
148 SDL_Unlock_EventThread(); 150 SDL_Unlock_EventThread();
149 151