Xext: saver: use dixDestroyPixmap() instead of direct driver call

Direct calls to ScreenRec->DestroyPixmap() blocks cleaning up the wrapping
jungle, so use the proper dix function instead.

See: https://gitlab.freedesktop.org/xorg/xserver/-/issues/1754

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1711>
This commit is contained in:
Enrico Weigelt, metux IT consult 2024-09-30 17:39:12 +02:00
parent 984da40fbb
commit 7ce19233bc

View File

@ -277,13 +277,10 @@ setEventMask(ScreenPtr pScreen, ClientPtr client, unsigned long mask)
static void
FreeAttrs(ScreenSaverAttrPtr pAttr)
{
PixmapPtr pPixmap;
CursorPtr pCursor;
if ((pPixmap = pAttr->pBackgroundPixmap) != 0)
(*pPixmap->drawable.pScreen->DestroyPixmap) (pPixmap);
if ((pPixmap = pAttr->pBorderPixmap) != 0)
(*pPixmap->drawable.pScreen->DestroyPixmap) (pPixmap);
dixDestroyPixmap(pAttr->pBackgroundPixmap, 0);
dixDestroyPixmap(pAttr->pBorderPixmap, 0);
if ((pCursor = pAttr->pCursor) != 0)
FreeCursor(pCursor, (Cursor) 0);
}