diff options
Diffstat (limited to 'xorg-server/Xext/panoramiX.c')
-rw-r--r-- | xorg-server/Xext/panoramiX.c | 80 |
1 files changed, 37 insertions, 43 deletions
diff --git a/xorg-server/Xext/panoramiX.c b/xorg-server/Xext/panoramiX.c index 2bbae2f5e..49b313df9 100644 --- a/xorg-server/Xext/panoramiX.c +++ b/xorg-server/Xext/panoramiX.c @@ -902,15 +902,14 @@ int ProcPanoramiXQueryVersion(ClientPtr client) { /* REQUEST(xPanoramiXQueryVersionReq); */ - xPanoramiXQueryVersionReply rep = { - .type = X_Reply, - .sequenceNumber = client->sequence, - .length = 0, - .majorVersion = SERVER_PANORAMIX_MAJOR_VERSION, - .minorVersion = SERVER_PANORAMIX_MINOR_VERSION - }; + xPanoramiXQueryVersionReply rep; REQUEST_SIZE_MATCH(xPanoramiXQueryVersionReq); + rep.type = X_Reply; + rep.sequenceNumber = client->sequence; + rep.length = 0; + rep.majorVersion = SERVER_PANORAMIX_MAJOR_VERSION; + rep.minorVersion = SERVER_PANORAMIX_MINOR_VERSION; if (client->swapped) { swaps(&rep.sequenceNumber); swapl(&rep.length); @@ -934,13 +933,12 @@ ProcPanoramiXGetState(ClientPtr client) if (rc != Success) return rc; - rep = (xPanoramiXGetStateReply) { - .type = X_Reply, - .state = !noPanoramiXExtension, - .sequenceNumber = client->sequence, - .length = 0, - .window = stuff->window - }; + + rep.type = X_Reply; + rep.state = !noPanoramiXExtension; + rep.sequenceNumber = client->sequence; + rep.length = 0; + rep.window = stuff->window; if (client->swapped) { swaps(&rep.sequenceNumber); swapl(&rep.length); @@ -964,13 +962,12 @@ ProcPanoramiXGetScreenCount(ClientPtr client) if (rc != Success) return rc; - rep = (xPanoramiXGetScreenCountReply) { - .type = X_Reply, - .ScreenCount = PanoramiXNumScreens, - .sequenceNumber = client->sequence, - .length = 0, - .window = stuff->window - }; + + rep.type = X_Reply; + rep.ScreenCount = PanoramiXNumScreens; + rep.sequenceNumber = client->sequence; + rep.length = 0; + rep.window = stuff->window; if (client->swapped) { swaps(&rep.sequenceNumber); swapl(&rep.length); @@ -996,16 +993,15 @@ ProcPanoramiXGetScreenSize(ClientPtr client) if (rc != Success) return rc; - rep = (xPanoramiXGetScreenSizeReply) { - .type = X_Reply, - .sequenceNumber = client->sequence, - .length = 0, + + rep.type = X_Reply; + rep.sequenceNumber = client->sequence; + rep.length = 0; /* screen dimensions */ - .width = screenInfo.screens[stuff->screen]->width, - .height = screenInfo.screens[stuff->screen]->height, - .window = stuff->window, - .screen = stuff->screen - }; + rep.width = screenInfo.screens[stuff->screen]->width; + rep.height = screenInfo.screens[stuff->screen]->height; + rep.window = stuff->window; + rep.screen = stuff->screen; if (client->swapped) { swaps(&rep.sequenceNumber); swapl(&rep.length); @@ -1026,18 +1022,17 @@ ProcXineramaIsActive(ClientPtr client) REQUEST_SIZE_MATCH(xXineramaIsActiveReq); - rep = (xXineramaIsActiveReply) { - .type = X_Reply, - .sequenceNumber = client->sequence, - .length = 0, + + rep.type = X_Reply; + rep.sequenceNumber = client->sequence; + rep.length = 0; #if 1 /* The following hack fools clients into thinking that Xinerama * is disabled even though it is not. */ - .state = !noPanoramiXExtension && !PanoramiXExtensionDisabledHack + rep.state = !noPanoramiXExtension && !PanoramiXExtensionDisabledHack; #else - .state = !noPanoramiXExtension; + rep.state = !noPanoramiXExtension; #endif - }; if (client->swapped) { swaps(&rep.sequenceNumber); swapl(&rep.length); @@ -1052,15 +1047,14 @@ ProcXineramaQueryScreens(ClientPtr client) { /* REQUEST(xXineramaQueryScreensReq); */ CARD32 number = (noPanoramiXExtension) ? 0 : PanoramiXNumScreens; - xXineramaQueryScreensReply rep = { - .type = X_Reply, - .sequenceNumber = client->sequence, - .length = bytes_to_int32(number * sz_XineramaScreenInfo), - .number = number - }; + xXineramaQueryScreensReply rep; REQUEST_SIZE_MATCH(xXineramaQueryScreensReq); + rep.type = X_Reply; + rep.sequenceNumber = client->sequence; + rep.length = bytes_to_int32(number * sz_XineramaScreenInfo); + rep.number = number; if (client->swapped) { swaps(&rep.sequenceNumber); swapl(&rep.length); |