summaryrefslogtreecommitdiff
path: root/test/xi2/protocol-xigetclientpointer.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/xi2/protocol-xigetclientpointer.c')
-rw-r--r--test/xi2/protocol-xigetclientpointer.c27
1 files changed, 15 insertions, 12 deletions
diff --git a/test/xi2/protocol-xigetclientpointer.c b/test/xi2/protocol-xigetclientpointer.c
index aec58908d..28eb8d32a 100644
--- a/test/xi2/protocol-xigetclientpointer.c
+++ b/test/xi2/protocol-xigetclientpointer.c
@@ -49,13 +49,14 @@ struct {
static ClientRec client_window;
static ClientRec client_request;
-int __wrap_dixLookupClient(ClientPtr *pClient, XID rid, ClientPtr client, Mask access)
+int
+__wrap_dixLookupClient(ClientPtr *pClient, XID rid, ClientPtr client,
+ Mask access)
{
if (rid == ROOT_WINDOW_ID)
return BadWindow;
- if (rid == CLIENT_WINDOW_ID)
- {
+ if (rid == CLIENT_WINDOW_ID) {
*pClient = &client_window;
return Success;
}
@@ -63,13 +64,12 @@ int __wrap_dixLookupClient(ClientPtr *pClient, XID rid, ClientPtr client, Mask a
return __real_dixLookupClient(pClient, rid, client, access);
}
-
-static void reply_XIGetClientPointer(ClientPtr client, int len, char *data, void *userdata)
+static void
+reply_XIGetClientPointer(ClientPtr client, int len, char *data, void *userdata)
{
- xXIGetClientPointerReply *rep = (xXIGetClientPointerReply*)data;
+ xXIGetClientPointerReply *rep = (xXIGetClientPointerReply *) data;
- if (client->swapped)
- {
+ if (client->swapped) {
swapl(&rep->length);
swaps(&rep->sequenceNumber);
swaps(&rep->deviceid);
@@ -82,7 +82,9 @@ static void reply_XIGetClientPointer(ClientPtr client, int len, char *data, void
assert(rep->deviceid == test_data.dev->id);
}
-static void request_XIGetClientPointer(ClientPtr client, xXIGetClientPointerReq* req, int error)
+static void
+request_XIGetClientPointer(ClientPtr client, xXIGetClientPointerReq * req,
+ int error)
{
int rc;
@@ -105,7 +107,8 @@ static void request_XIGetClientPointer(ClientPtr client, xXIGetClientPointerReq*
}
-static void test_XIGetClientPointer(void)
+static void
+test_XIGetClientPointer(void)
{
xXIGetClientPointerReq request;
@@ -113,7 +116,6 @@ static void test_XIGetClientPointer(void)
request.win = CLIENT_WINDOW_ID;
-
reply_handler = reply_XIGetClientPointer;
client_request = init_client(request.length, &request);
@@ -149,7 +151,8 @@ static void test_XIGetClientPointer(void)
request_XIGetClientPointer(&client_request, &request, Success);
}
-int main(int argc, char** argv)
+int
+main(int argc, char **argv)
{
init_simple();
client_window = init_client(0, NULL);