dix: AllocColor() dont fire Xace hook when looking up color at root window

This is creating false alarms that are complicated to catch, thus passing
NULL client so the Xace hook in dixLookupResourceByType() doesn't fire here.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
Enrico Weigelt, metux IT consult 2025-03-10 20:00:00 +01:00
parent b73cd6066a
commit dc0630df2f

View File

@ -1026,7 +1026,7 @@ AllocColor(ColormapPtr pmap,
dixLookupResourceByType((void **) &prootmap, dixLookupResourceByType((void **) &prootmap,
pmap->pScreen->defColormap, X11_RESTYPE_COLORMAP, pmap->pScreen->defColormap, X11_RESTYPE_COLORMAP,
clients[client], DixReadAccess); NULL, DixReadAccess);
if (pmap->class == prootmap->class) if (pmap->class == prootmap->class)
FindColorInRootCmap(prootmap, prootmap->red, entries, &rgb, FindColorInRootCmap(prootmap, prootmap->red, entries, &rgb,
@ -1044,7 +1044,7 @@ AllocColor(ColormapPtr pmap,
dixLookupResourceByType((void **) &prootmap, dixLookupResourceByType((void **) &prootmap,
pmap->pScreen->defColormap, X11_RESTYPE_COLORMAP, pmap->pScreen->defColormap, X11_RESTYPE_COLORMAP,
clients[client], DixReadAccess); NULL, DixReadAccess);
if (pmap->class == prootmap->class) { if (pmap->class == prootmap->class) {
pixR = (*pPix & pVisual->redMask) >> pVisual->offsetRed; pixR = (*pPix & pVisual->redMask) >> pVisual->offsetRed;