diff options
author | Alan Coopersmith <alan.coopersmith@oracle.com> | 2012-07-09 19:12:43 -0700 |
---|---|---|
committer | Alan Coopersmith <alan.coopersmith@oracle.com> | 2012-07-09 19:58:30 -0700 |
commit | 2f5caeaddb3616dc9ff57d784f7feba589c536e7 (patch) | |
tree | 1909962a69a7a643c6f66b0320416cbdca191e59 /Xi/getmmap.c | |
parent | 6a721e3af5e11bae1d59ca551a02470f35d9e844 (diff) |
Use C99 designated initializers in Xinput Replies
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 'Xi/getmmap.c')
-rw-r--r-- | Xi/getmmap.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/Xi/getmmap.c b/Xi/getmmap.c index 97d4c0d87..f07f2bb5c 100644 --- a/Xi/getmmap.c +++ b/Xi/getmmap.c @@ -101,12 +101,14 @@ ProcXGetDeviceModifierMapping(ClientPtr client) if (ret != Success) return ret; - rep.repType = X_Reply; - rep.RepType = X_GetDeviceModifierMapping; - rep.numKeyPerModifier = max_keys_per_mod; - rep.sequenceNumber = client->sequence; + rep = (xGetDeviceModifierMappingReply) { + .repType = X_Reply, + .RepType = X_GetDeviceModifierMapping, + .sequenceNumber = client->sequence, + .numKeyPerModifier = max_keys_per_mod, /* length counts 4 byte quantities - there are 8 modifiers 1 byte big */ - rep.length = max_keys_per_mod << 1; + .length = max_keys_per_mod << 1 + }; WriteReplyToClient(client, sizeof(xGetDeviceModifierMappingReply), &rep); WriteToClient(client, max_keys_per_mod * 8, modkeymap); |