[PATCH 08/29] barriers: Don't allow releasing the pointer on other client's barriers

Peter Hutterer peter.hutterer at who-t.net
Tue Dec 11 23:19:01 PST 2012


Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
---
 Xi/xibarriers.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/Xi/xibarriers.c b/Xi/xibarriers.c
index 86e811e..8f12253 100644
--- a/Xi/xibarriers.c
+++ b/Xi/xibarriers.c
@@ -591,6 +591,9 @@ ProcXIBarrierReleasePointer(ClientPtr client)
             return err;
         }
 
+        if (CLIENT_ID(barrier_id) != client->index)
+            return BadAccess;
+
         barrier = container_of(b, struct PointerBarrierClient, barrier);
         if (barrier->barrier_event_id == event_id)
             barrier->release_event_id = event_id;
-- 
1.8.0.1



More information about the xorg-devel mailing list