xace: typesafe hook function for XACE_RESOURCE_ACCESS

The generic XaceHook() call isn't typesafe (und unnecessarily slow).
Better add an explicit function, just like we already have for others.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1556>
This commit is contained in:
Enrico Weigelt, metux IT consult
2024-05-16 17:49:33 +02:00
committed by Marge Bot
parent 632a48a057
commit ae3c573337
18 changed files with 46 additions and 46 deletions

View File

@@ -373,7 +373,7 @@ ProcXFixesGetCursorImage(ClientPtr client)
pCursor = CursorForClient(client);
if (!pCursor)
return BadCursor;
rc = XaceHook(XACE_RESOURCE_ACCESS, client, pCursor->id, X11_RESTYPE_CURSOR,
rc = XaceHookResourceAccess(client, pCursor->id, X11_RESTYPE_CURSOR,
pCursor, X11_RESTYPE_NONE, NULL, DixReadAccess);
if (rc != Success)
return rc;
@@ -522,7 +522,7 @@ ProcXFixesGetCursorImageAndName(ClientPtr client)
pCursor = CursorForClient(client);
if (!pCursor)
return BadCursor;
rc = XaceHook(XACE_RESOURCE_ACCESS, client, pCursor->id, X11_RESTYPE_CURSOR,
rc = XaceHookResourceAccess(client, pCursor->id, X11_RESTYPE_CURSOR,
pCursor, X11_RESTYPE_NONE, NULL, DixReadAccess | DixGetAttrAccess);
if (rc != Success)
return rc;