summaryrefslogtreecommitdiff
path: root/mi
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2012-07-09 19:12:44 -0700
committerKeith Packard <keithp@keithp.com>2012-07-09 22:52:30 -0700
commit0af79b124e1317c36d1613d28755c5a8ce612e2a (patch)
treec2f450fa9e6c7bda1025a80a59fb7887642d3a07 /mi
parent483266a583b0fd8a552303f318a71502ce3ff1d2 (diff)
Use C99 designated initializers in dix Events
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> Reviewed-by: Keith Packard <keithp@keithp.com> Tested-by: Daniel Stone <daniel@fooishbar.org>
Diffstat (limited to 'mi')
-rw-r--r--mi/miexpose.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/mi/miexpose.c b/mi/miexpose.c
index 2dc465d9c..8b7c93fb8 100644
--- a/mi/miexpose.c
+++ b/mi/miexpose.c
@@ -349,13 +349,12 @@ miSendGraphicsExpose(ClientPtr client, RegionPtr pRgn, XID drawable,
free(pEvent);
}
else {
- xEvent event;
-
- memset(&event, 0, sizeof(xEvent));
+ xEvent event = {
+ .u.noExposure.drawable = drawable,
+ .u.noExposure.majorEvent = major,
+ .u.noExposure.minorEvent = minor
+ };
event.u.u.type = NoExpose;
- event.u.noExposure.drawable = drawable;
- event.u.noExposure.majorEvent = major;
- event.u.noExposure.minorEvent = minor;
WriteEventsToClient(client, 1, &event);
}
}