summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArnaud Fontaine <arnau@debian.org>2009-12-16 00:55:20 +0100
committerArnaud Fontaine <arfontaine@ITEM-58736.dhcp.oxfd.uk.sopra>2010-02-11 14:47:30 +0000
commit95f205f6acb9cbb71c44b5902a8d22416abdc910 (patch)
tree0fb2ecef62c713bbbff39140844a89c1f13e77ae
parentd164e75cae28de01f39fafa2b2b32cbaeb14b8d9 (diff)
xcb_ewmh_send_client_message: check whether the data fit the ClientMessage
-rw-r--r--ewmh/ewmh.c.m42
1 files changed, 2 insertions, 0 deletions
diff --git a/ewmh/ewmh.c.m4 b/ewmh/ewmh.c.m4
index 0b3fb09..50e49a0 100644
--- a/ewmh/ewmh.c.m4
+++ b/ewmh/ewmh.c.m4
@@ -491,6 +491,8 @@ xcb_ewmh_send_client_message(xcb_connection_t *c,
ev.format = 32;
ev.type = atom;
+ assert(data_len <= (5 * sizeof(uint32_t)));
+
memcpy(ev.data.data32, data, data_len);
return xcb_send_event(c, 0, dest, XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY |