fix memory leak

This commit is contained in:
Christopher Jeffrey 2011-11-04 04:01:45 -05:00
parent b0608d0c7c
commit 7d17fcdf1e
1 changed files with 15 additions and 9 deletions

View File

@ -1635,6 +1635,12 @@ finish_destroy_win(Display *dpy, Window id) {
w->shadow_pict = None;
}
/* fix leak, from freedesktop repo */
if (w->shadow) {
XRenderFreePicture (dpy, w->shadow);
w->shadow = None;
}
if (w->damage != None) {
set_ignore(dpy, NextRequest(dpy));
XDamageDestroy(dpy, w->damage);