[PATCH 20/22] xkb: Remove some fascinating paranoia from event emission

Adam Jackson ajax at redhat.com
Tue Jul 22 08:46:40 PDT 2014


XkbInterestPtrs are created by clients that already exist, meaning,
clients that have already had ProcVector installed as something other
than InitialProcVector.

Signed-off-by: Adam Jackson <ajax at redhat.com>
---
 xkb/xkbEvents.c | 9 ---------
 1 file changed, 9 deletions(-)

diff --git a/xkb/xkbEvents.c b/xkb/xkbEvents.c
index 210d8eb..cc9a535 100644
--- a/xkb/xkbEvents.c
+++ b/xkb/xkbEvents.c
@@ -237,7 +237,6 @@ XkbSendStateNotify(DeviceIntPtr kbd, xkbStateNotify * pSN)
 
     while (interest) {
         if ((!interest->client->clientGone) &&
-            (interest->client->requestVector != InitialVector) &&
             (interest->client->xkbClientFlags & _XkbClientInitialized) &&
             (interest->stateNotifyMask & changed)) {
             pSN->sequenceNumber = interest->client->sequence;
@@ -400,7 +399,6 @@ XkbSendControlsNotify(DeviceIntPtr kbd, xkbControlsNotify * pCN)
     pCN->numGroups = xkbi->desc->ctrls->num_groups;
     while (interest) {
         if ((!interest->client->clientGone) &&
-            (interest->client->requestVector != InitialVector) &&
             (interest->client->xkbClientFlags & _XkbClientInitialized) &&
             (interest->ctrlsNotifyMask & changedControls)) {
             if (!initialized) {
@@ -447,7 +445,6 @@ XkbSendIndicatorNotify(DeviceIntPtr kbd, int xkbType, xkbIndicatorNotify * pEv)
     changed = pEv->changed;
     while (interest) {
         if ((!interest->client->clientGone) &&
-            (interest->client->requestVector != InitialVector) &&
             (interest->client->xkbClientFlags & _XkbClientInitialized) &&
             (((xkbType == XkbIndicatorStateNotify) &&
               (interest->iStateNotifyMask & changed)) ||
@@ -528,7 +525,6 @@ XkbHandleBell(BOOL force,
     initialized = 0;
     while (interest) {
         if ((!interest->client->clientGone) &&
-            (interest->client->requestVector != InitialVector) &&
             (interest->client->xkbClientFlags & _XkbClientInitialized) &&
             (interest->bellNotifyMask)) {
             if (!initialized) {
@@ -581,7 +577,6 @@ XkbSendAccessXNotify(DeviceIntPtr kbd, xkbAccessXNotify * pEv)
     db_delay = pEv->debounceDelay;
     while (interest) {
         if ((!interest->client->clientGone) &&
-            (interest->client->requestVector != InitialVector) &&
             (interest->client->xkbClientFlags & _XkbClientInitialized) &&
             (interest->accessXNotifyMask & (1 << pEv->detail))) {
             if (!initialized) {
@@ -627,7 +622,6 @@ XkbSendNamesNotify(DeviceIntPtr kbd, xkbNamesNotify * pEv)
     changedVirtualMods = pEv->changedVirtualMods;
     while (interest) {
         if ((!interest->client->clientGone) &&
-            (interest->client->requestVector != InitialVector) &&
             (interest->client->xkbClientFlags & _XkbClientInitialized) &&
             (interest->namesNotifyMask & pEv->changed)) {
             if (!initialized) {
@@ -671,7 +665,6 @@ XkbSendCompatMapNotify(DeviceIntPtr kbd, xkbCompatMapNotify * pEv)
     initialized = 0;
     while (interest) {
         if ((!interest->client->clientGone) &&
-            (interest->client->requestVector != InitialVector) &&
             (interest->client->xkbClientFlags & _XkbClientInitialized) &&
             (interest->compatNotifyMask)) {
             if (!initialized) {
@@ -722,7 +715,6 @@ XkbSendActionMessage(DeviceIntPtr kbd, xkbActionMessage * pEv)
     pEv->group = xkbi->state.group;
     while (interest) {
         if ((!interest->client->clientGone) &&
-            (interest->client->requestVector != InitialVector) &&
             (interest->client->xkbClientFlags & _XkbClientInitialized) &&
             (interest->actionMessageMask)) {
             if (!initialized) {
@@ -766,7 +758,6 @@ XkbSendExtensionDeviceNotify(DeviceIntPtr dev,
     state = pEv->ledState;
     while (interest) {
         if ((!interest->client->clientGone) &&
-            (interest->client->requestVector != InitialVector) &&
             (interest->client->xkbClientFlags & _XkbClientInitialized) &&
             (interest->extDevNotifyMask & reason)) {
             if (!initialized) {
-- 
1.9.3



More information about the xorg-devel mailing list