From: "Jasper St. Pierre" <[email protected]>

This code was wrongly changed when the patches were landed. If this is
changed from an array to a pointer, then it would have to point somewhere.
We're allocating the device IDs array inline with the main structure as a
flexible array, so we can't use a pointer, as it will point at garbage when
we try to write to it.

Signed-off-by: Jasper St. Pierre <[email protected]>
---
 xfixes/cursor.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/xfixes/cursor.c b/xfixes/cursor.c
index 7c223dd..7ca48c8 100644
--- a/xfixes/cursor.c
+++ b/xfixes/cursor.c
@@ -120,7 +120,7 @@ struct PointerBarrierClient {
     struct PointerBarrier barrier;
     struct xorg_list entry;
     int num_devices;
-    int *device_ids; /* num_devices */
+    int device_ids[0]; /* num_devices */
 };
 
 /*
-- 
1.8.0

_______________________________________________
[email protected]: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to