summaryrefslogtreecommitdiff
path: root/xfixes/select.c
diff options
context:
space:
mode:
authorEamon Walsh <ewalsh@tycho.nsa.gov>2007-08-30 11:48:45 -0400
committerEamon Walsh <ewalsh@moss-charon.epoch.ncsc.mil>2007-08-30 11:48:45 -0400
commitcda92bbf12107865e93c03c71b901ef51466dc31 (patch)
treebdf01af62041494641280badc88b2fec197856b6 /xfixes/select.c
parent47ab4d648b31ea1d5800e0bc84cf5f25025bffe3 (diff)
xace: add hooks + new access codes: XFixes extension.
Required a new name argument to the selection access hook to handle XFixesSelectSelectionInput.
Diffstat (limited to 'xfixes/select.c')
-rwxr-xr-xxfixes/select.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/xfixes/select.c b/xfixes/select.c
index c0076801d..9de152f29 100755
--- a/xfixes/select.c
+++ b/xfixes/select.c
@@ -25,6 +25,7 @@
#endif
#include "xfixesint.h"
+#include "xace.h"
static RESTYPE SelectionClientType, SelectionWindowType;
static Bool SelectionCallbackRegistered = FALSE;
@@ -131,8 +132,14 @@ XFixesSelectSelectionInput (ClientPtr pClient,
WindowPtr pWindow,
CARD32 eventMask)
{
+ int rc;
SelectionEventPtr *prev, e;
+ rc = XaceHook(XACE_SELECTION_ACCESS, pClient, selection, NULL,
+ DixGetAttrAccess);
+ if (rc != Success)
+ return rc;
+
for (prev = &selectionEvents; (e = *prev); prev = &e->next)
{
if (e->selection == selection &&
@@ -196,7 +203,7 @@ ProcXFixesSelectSelectionInput (ClientPtr client)
int rc;
REQUEST_SIZE_MATCH (xXFixesSelectSelectionInputReq);
- rc = dixLookupWindow(&pWin, stuff->window, client, DixReadAccess);
+ rc = dixLookupWindow(&pWin, stuff->window, client, DixSetAttrAccess);
if (rc != Success)
return rc;
if (stuff->eventMask & ~SelectionAllEvents)