diff options
Diffstat (limited to 'nx-X11/programs/Xserver/dix/swapreq.c')
-rw-r--r-- | nx-X11/programs/Xserver/dix/swapreq.c | 728 |
1 files changed, 323 insertions, 405 deletions
diff --git a/nx-X11/programs/Xserver/dix/swapreq.c b/nx-X11/programs/Xserver/dix/swapreq.c index 35a7e7527..e5ac71710 100644 --- a/nx-X11/programs/Xserver/dix/swapreq.c +++ b/nx-X11/programs/Xserver/dix/swapreq.c @@ -68,23 +68,21 @@ SOFTWARE. void SwapLongs (register CARD32 *list, register unsigned long count) { - register char n; - while (count >= 8) { - swapl(list+0, n); - swapl(list+1, n); - swapl(list+2, n); - swapl(list+3, n); - swapl(list+4, n); - swapl(list+5, n); - swapl(list+6, n); - swapl(list+7, n); + swapl(list+0); + swapl(list+1); + swapl(list+2); + swapl(list+3); + swapl(list+4); + swapl(list+5); + swapl(list+6); + swapl(list+7); list += 8; count -= 8; } if (count != 0) { do { - swapl(list, n); + swapl(list); list++; } while (--count != 0); } @@ -95,31 +93,29 @@ SwapLongs (register CARD32 *list, register unsigned long count) void SwapShorts (register short *list, register unsigned long count) { - register char n; - while (count >= 16) { - swaps(list+0, n); - swaps(list+1, n); - swaps(list+2, n); - swaps(list+3, n); - swaps(list+4, n); - swaps(list+5, n); - swaps(list+6, n); - swaps(list+7, n); - swaps(list+8, n); - swaps(list+9, n); - swaps(list+10, n); - swaps(list+11, n); - swaps(list+12, n); - swaps(list+13, n); - swaps(list+14, n); - swaps(list+15, n); + swaps(list+0); + swaps(list+1); + swaps(list+2); + swaps(list+3); + swaps(list+4); + swaps(list+5); + swaps(list+6); + swaps(list+7); + swaps(list+8); + swaps(list+9); + swaps(list+10); + swaps(list+11); + swaps(list+12); + swaps(list+13); + swaps(list+14); + swaps(list+15); list += 16; count -= 16; } if (count != 0) { do { - swaps(list, n); + swaps(list); list++; } while (--count != 0); } @@ -130,10 +126,8 @@ SwapShorts (register short *list, register unsigned long count) int SProcSimpleReq(register ClientPtr client) { - register char n; - REQUEST(xReq); - swaps(&stuff->length, n); + swaps(&stuff->length); return(*ProcVector[stuff->reqType])(client); } @@ -143,33 +137,29 @@ SProcSimpleReq(register ClientPtr client) int SProcResourceReq(register ClientPtr client) { - register char n; - REQUEST(xResourceReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xResourceReq); /* not EXACT */ - swapl(&stuff->id, n); + swapl(&stuff->id); return(*ProcVector[stuff->reqType])(client); } int SProcCreateWindow(register ClientPtr client) { - register char n; - REQUEST(xCreateWindowReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xCreateWindowReq); - swapl(&stuff->wid, n); - swapl(&stuff->parent, n); - swaps(&stuff->x, n); - swaps(&stuff->y, n); - swaps(&stuff->width, n); - swaps(&stuff->height, n); - swaps(&stuff->borderWidth, n); - swaps(&stuff->class, n); - swapl(&stuff->visual, n); - swapl(&stuff->mask, n); + swapl(&stuff->wid); + swapl(&stuff->parent); + swaps(&stuff->x); + swaps(&stuff->y); + swaps(&stuff->width); + swaps(&stuff->height); + swaps(&stuff->borderWidth); + swaps(&stuff->class); + swapl(&stuff->visual); + swapl(&stuff->mask); SwapRestL(stuff); return((* ProcVector[X_CreateWindow])(client)); } @@ -177,13 +167,11 @@ SProcCreateWindow(register ClientPtr client) int SProcChangeWindowAttributes(register ClientPtr client) { - register char n; - REQUEST(xChangeWindowAttributesReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xChangeWindowAttributesReq); - swapl(&stuff->window, n); - swapl(&stuff->valueMask, n); + swapl(&stuff->window); + swapl(&stuff->valueMask); SwapRestL(stuff); return((* ProcVector[X_ChangeWindowAttributes])(client)); } @@ -191,26 +179,24 @@ SProcChangeWindowAttributes(register ClientPtr client) int SProcReparentWindow(register ClientPtr client) { - register char n; REQUEST(xReparentWindowReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xReparentWindowReq); - swapl(&stuff->window, n); - swapl(&stuff->parent, n); - swaps(&stuff->x, n); - swaps(&stuff->y, n); + swapl(&stuff->window); + swapl(&stuff->parent); + swaps(&stuff->x); + swaps(&stuff->y); return((* ProcVector[X_ReparentWindow])(client)); } int SProcConfigureWindow(register ClientPtr client) { - register char n; REQUEST(xConfigureWindowReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xConfigureWindowReq); - swapl(&stuff->window, n); - swaps(&stuff->mask, n); + swapl(&stuff->window); + swaps(&stuff->mask); SwapRestL(stuff); return((* ProcVector[X_ConfigureWindow])(client)); @@ -220,25 +206,23 @@ SProcConfigureWindow(register ClientPtr client) int SProcInternAtom(register ClientPtr client) { - register char n; REQUEST(xInternAtomReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xInternAtomReq); - swaps(&stuff->nbytes, n); + swaps(&stuff->nbytes); return((* ProcVector[X_InternAtom])(client)); } int SProcChangeProperty(register ClientPtr client) { - register char n; REQUEST(xChangePropertyReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xChangePropertyReq); - swapl(&stuff->window, n); - swapl(&stuff->property, n); - swapl(&stuff->type, n); - swapl(&stuff->nUnits, n); + swapl(&stuff->window); + swapl(&stuff->property); + swapl(&stuff->type); + swapl(&stuff->nUnits); switch ( stuff->format ) { case 8 : break; @@ -255,12 +239,11 @@ SProcChangeProperty(register ClientPtr client) int SProcDeleteProperty(register ClientPtr client) { - register char n; REQUEST(xDeletePropertyReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xDeletePropertyReq); - swapl(&stuff->window, n); - swapl(&stuff->property, n); + swapl(&stuff->window); + swapl(&stuff->property); return((* ProcVector[X_DeleteProperty])(client)); } @@ -268,57 +251,53 @@ SProcDeleteProperty(register ClientPtr client) int SProcGetProperty(register ClientPtr client) { - register char n; REQUEST(xGetPropertyReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xGetPropertyReq); - swapl(&stuff->window, n); - swapl(&stuff->property, n); - swapl(&stuff->type, n); - swapl(&stuff->longOffset, n); - swapl(&stuff->longLength, n); + swapl(&stuff->window); + swapl(&stuff->property); + swapl(&stuff->type); + swapl(&stuff->longOffset); + swapl(&stuff->longLength); return((* ProcVector[X_GetProperty])(client)); } int SProcSetSelectionOwner(register ClientPtr client) { - register char n; REQUEST(xSetSelectionOwnerReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xSetSelectionOwnerReq); - swapl(&stuff->window, n); - swapl(&stuff->selection, n); - swapl(&stuff->time, n); + swapl(&stuff->window); + swapl(&stuff->selection); + swapl(&stuff->time); return((* ProcVector[X_SetSelectionOwner])(client)); } int SProcConvertSelection(register ClientPtr client) { - register char n; REQUEST(xConvertSelectionReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xConvertSelectionReq); - swapl(&stuff->requestor, n); - swapl(&stuff->selection, n); - swapl(&stuff->target, n); - swapl(&stuff->property, n); - swapl(&stuff->time, n); + swapl(&stuff->requestor); + swapl(&stuff->selection); + swapl(&stuff->target); + swapl(&stuff->property); + swapl(&stuff->time); return((* ProcVector[X_ConvertSelection])(client)); } int SProcSendEvent(register ClientPtr client) { - register char n; xEvent eventT; EventSwapPtr proc; REQUEST(xSendEventReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xSendEventReq); - swapl(&stuff->destination, n); - swapl(&stuff->eventMask, n); + swapl(&stuff->destination); + swapl(&stuff->eventMask); /* Swap event */ proc = EventSwapVector[stuff->event.u.u.type & 0177]; @@ -333,223 +312,206 @@ SProcSendEvent(register ClientPtr client) int SProcGrabPointer(register ClientPtr client) { - register char n; REQUEST(xGrabPointerReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xGrabPointerReq); - swapl(&stuff->grabWindow, n); - swaps(&stuff->eventMask, n); - swapl(&stuff->confineTo, n); - swapl(&stuff->cursor, n); - swapl(&stuff->time, n); + swapl(&stuff->grabWindow); + swaps(&stuff->eventMask); + swapl(&stuff->confineTo); + swapl(&stuff->cursor); + swapl(&stuff->time); return((* ProcVector[X_GrabPointer])(client)); } int SProcGrabButton(register ClientPtr client) { - register char n; REQUEST(xGrabButtonReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xGrabButtonReq); - swapl(&stuff->grabWindow, n); - swaps(&stuff->eventMask, n); - swapl(&stuff->confineTo, n); - swapl(&stuff->cursor, n); - swaps(&stuff->modifiers, n); + swapl(&stuff->grabWindow); + swaps(&stuff->eventMask); + swapl(&stuff->confineTo); + swapl(&stuff->cursor); + swaps(&stuff->modifiers); return((* ProcVector[X_GrabButton])(client)); } int SProcUngrabButton(register ClientPtr client) { - register char n; REQUEST(xUngrabButtonReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xUngrabButtonReq); - swapl(&stuff->grabWindow, n); - swaps(&stuff->modifiers, n); + swapl(&stuff->grabWindow); + swaps(&stuff->modifiers); return((* ProcVector[X_UngrabButton])(client)); } int SProcChangeActivePointerGrab(register ClientPtr client) { - register char n; REQUEST(xChangeActivePointerGrabReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xChangeActivePointerGrabReq); - swapl(&stuff->cursor, n); - swapl(&stuff->time, n); - swaps(&stuff->eventMask, n); + swapl(&stuff->cursor); + swapl(&stuff->time); + swaps(&stuff->eventMask); return((* ProcVector[X_ChangeActivePointerGrab])(client)); } int SProcGrabKeyboard(register ClientPtr client) { - register char n; REQUEST(xGrabKeyboardReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xGrabKeyboardReq); - swapl(&stuff->grabWindow, n); - swapl(&stuff->time, n); + swapl(&stuff->grabWindow); + swapl(&stuff->time); return((* ProcVector[X_GrabKeyboard])(client)); } int SProcGrabKey(register ClientPtr client) { - register char n; REQUEST(xGrabKeyReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xGrabKeyReq); - swapl(&stuff->grabWindow, n); - swaps(&stuff->modifiers, n); + swapl(&stuff->grabWindow); + swaps(&stuff->modifiers); return((* ProcVector[X_GrabKey])(client)); } int SProcUngrabKey(register ClientPtr client) { - register char n; REQUEST(xUngrabKeyReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xUngrabKeyReq); - swapl(&stuff->grabWindow, n); - swaps(&stuff->modifiers, n); + swapl(&stuff->grabWindow); + swaps(&stuff->modifiers); return((* ProcVector[X_UngrabKey])(client)); } int SProcGetMotionEvents(register ClientPtr client) { - register char n; REQUEST(xGetMotionEventsReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xGetMotionEventsReq); - swapl(&stuff->window, n); - swapl(&stuff->start, n); - swapl(&stuff->stop, n); + swapl(&stuff->window); + swapl(&stuff->start); + swapl(&stuff->stop); return((* ProcVector[X_GetMotionEvents])(client)); } int SProcTranslateCoords(register ClientPtr client) { - register char n; REQUEST(xTranslateCoordsReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xTranslateCoordsReq); - swapl(&stuff->srcWid, n); - swapl(&stuff->dstWid, n); - swaps(&stuff->srcX, n); - swaps(&stuff->srcY, n); + swapl(&stuff->srcWid); + swapl(&stuff->dstWid); + swaps(&stuff->srcX); + swaps(&stuff->srcY); return((* ProcVector[X_TranslateCoords])(client)); } int SProcWarpPointer(register ClientPtr client) { - register char n; REQUEST(xWarpPointerReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xWarpPointerReq); - swapl(&stuff->srcWid, n); - swapl(&stuff->dstWid, n); - swaps(&stuff->srcX, n); - swaps(&stuff->srcY, n); - swaps(&stuff->srcWidth, n); - swaps(&stuff->srcHeight, n); - swaps(&stuff->dstX, n); - swaps(&stuff->dstY, n); + swapl(&stuff->srcWid); + swapl(&stuff->dstWid); + swaps(&stuff->srcX); + swaps(&stuff->srcY); + swaps(&stuff->srcWidth); + swaps(&stuff->srcHeight); + swaps(&stuff->dstX); + swaps(&stuff->dstY); return((* ProcVector[X_WarpPointer])(client)); } int SProcSetInputFocus(register ClientPtr client) { - register char n; REQUEST(xSetInputFocusReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xSetInputFocusReq); - swapl(&stuff->focus, n); - swapl(&stuff->time, n); + swapl(&stuff->focus); + swapl(&stuff->time); return((* ProcVector[X_SetInputFocus])(client)); } int SProcOpenFont(register ClientPtr client) { - register char n; REQUEST(xOpenFontReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xOpenFontReq); - swapl(&stuff->fid, n); - swaps(&stuff->nbytes, n); + swapl(&stuff->fid); + swaps(&stuff->nbytes); return((* ProcVector[X_OpenFont])(client)); } int SProcListFonts(register ClientPtr client) { - register char n; REQUEST(xListFontsReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xListFontsReq); - swaps(&stuff->maxNames, n); - swaps(&stuff->nbytes, n); + swaps(&stuff->maxNames); + swaps(&stuff->nbytes); return((* ProcVector[X_ListFonts])(client)); } int SProcListFontsWithInfo(register ClientPtr client) { - register char n; REQUEST(xListFontsWithInfoReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xListFontsWithInfoReq); - swaps(&stuff->maxNames, n); - swaps(&stuff->nbytes, n); + swaps(&stuff->maxNames); + swaps(&stuff->nbytes); return((* ProcVector[X_ListFontsWithInfo])(client)); } int SProcSetFontPath(register ClientPtr client) { - register char n; REQUEST(xSetFontPathReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xSetFontPathReq); - swaps(&stuff->nFonts, n); + swaps(&stuff->nFonts); return((* ProcVector[X_SetFontPath])(client)); } int SProcCreatePixmap(register ClientPtr client) { - register char n; REQUEST(xCreatePixmapReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xCreatePixmapReq); - swapl(&stuff->pid, n); - swapl(&stuff->drawable, n); - swaps(&stuff->width, n); - swaps(&stuff->height, n); + swapl(&stuff->pid); + swapl(&stuff->drawable); + swaps(&stuff->width); + swaps(&stuff->height); return((* ProcVector[X_CreatePixmap])(client)); } int SProcCreateGC(register ClientPtr client) { - register char n; REQUEST(xCreateGCReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xCreateGCReq); - swapl(&stuff->gc, n); - swapl(&stuff->drawable, n); - swapl(&stuff->mask, n); + swapl(&stuff->gc); + swapl(&stuff->drawable); + swapl(&stuff->mask); SwapRestL(stuff); return((* ProcVector[X_CreateGC])(client)); } @@ -557,12 +519,11 @@ SProcCreateGC(register ClientPtr client) int SProcChangeGC(register ClientPtr client) { - register char n; REQUEST(xChangeGCReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xChangeGCReq); - swapl(&stuff->gc, n); - swapl(&stuff->mask, n); + swapl(&stuff->gc); + swapl(&stuff->mask); SwapRestL(stuff); return((* ProcVector[X_ChangeGC])(client)); } @@ -570,26 +531,24 @@ SProcChangeGC(register ClientPtr client) int SProcCopyGC(register ClientPtr client) { - register char n; REQUEST(xCopyGCReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xCopyGCReq); - swapl(&stuff->srcGC, n); - swapl(&stuff->dstGC, n); - swapl(&stuff->mask, n); + swapl(&stuff->srcGC); + swapl(&stuff->dstGC); + swapl(&stuff->mask); return((* ProcVector[X_CopyGC])(client)); } int SProcSetDashes(register ClientPtr client) { - register char n; REQUEST(xSetDashesReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xSetDashesReq); - swapl(&stuff->gc, n); - swaps(&stuff->dashOffset, n); - swaps(&stuff->nDashes, n); + swapl(&stuff->gc); + swaps(&stuff->dashOffset); + swaps(&stuff->nDashes); return((* ProcVector[X_SetDashes])(client)); } @@ -597,13 +556,12 @@ SProcSetDashes(register ClientPtr client) int SProcSetClipRectangles(register ClientPtr client) { - register char n; REQUEST(xSetClipRectanglesReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xSetClipRectanglesReq); - swapl(&stuff->gc, n); - swaps(&stuff->xOrigin, n); - swaps(&stuff->yOrigin, n); + swapl(&stuff->gc); + swaps(&stuff->xOrigin); + swaps(&stuff->yOrigin); SwapRestS(stuff); return((* ProcVector[X_SetClipRectangles])(client)); } @@ -611,54 +569,51 @@ SProcSetClipRectangles(register ClientPtr client) int SProcClearToBackground(register ClientPtr client) { - register char n; REQUEST(xClearAreaReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xClearAreaReq); - swapl(&stuff->window, n); - swaps(&stuff->x, n); - swaps(&stuff->y, n); - swaps(&stuff->width, n); - swaps(&stuff->height, n); + swapl(&stuff->window); + swaps(&stuff->x); + swaps(&stuff->y); + swaps(&stuff->width); + swaps(&stuff->height); return((* ProcVector[X_ClearArea])(client)); } int SProcCopyArea(register ClientPtr client) { - register char n; REQUEST(xCopyAreaReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xCopyAreaReq); - swapl(&stuff->srcDrawable, n); - swapl(&stuff->dstDrawable, n); - swapl(&stuff->gc, n); - swaps(&stuff->srcX, n); - swaps(&stuff->srcY, n); - swaps(&stuff->dstX, n); - swaps(&stuff->dstY, n); - swaps(&stuff->width, n); - swaps(&stuff->height, n); + swapl(&stuff->srcDrawable); + swapl(&stuff->dstDrawable); + swapl(&stuff->gc); + swaps(&stuff->srcX); + swaps(&stuff->srcY); + swaps(&stuff->dstX); + swaps(&stuff->dstY); + swaps(&stuff->width); + swaps(&stuff->height); return((* ProcVector[X_CopyArea])(client)); } int SProcCopyPlane(register ClientPtr client) { - register char n; REQUEST(xCopyPlaneReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xCopyPlaneReq); - swapl(&stuff->srcDrawable, n); - swapl(&stuff->dstDrawable, n); - swapl(&stuff->gc, n); - swaps(&stuff->srcX, n); - swaps(&stuff->srcY, n); - swaps(&stuff->dstX, n); - swaps(&stuff->dstY, n); - swaps(&stuff->width, n); - swaps(&stuff->height, n); - swapl(&stuff->bitPlane, n); + swapl(&stuff->srcDrawable); + swapl(&stuff->dstDrawable); + swapl(&stuff->gc); + swaps(&stuff->srcX); + swaps(&stuff->srcY); + swaps(&stuff->dstX); + swaps(&stuff->dstY); + swaps(&stuff->width); + swaps(&stuff->height); + swapl(&stuff->bitPlane); return((* ProcVector[X_CopyPlane])(client)); } @@ -667,13 +622,11 @@ SProcCopyPlane(register ClientPtr client) int SProcPoly(register ClientPtr client) { - register char n; - REQUEST(xPolyPointReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xPolyPointReq); - swapl(&stuff->drawable, n); - swapl(&stuff->gc, n); + swapl(&stuff->drawable); + swapl(&stuff->gc); SwapRestS(stuff); return((* ProcVector[stuff->reqType])(client)); } @@ -684,13 +637,11 @@ SProcPoly(register ClientPtr client) int SProcFillPoly(register ClientPtr client) { - register char n; - REQUEST(xFillPolyReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xFillPolyReq); - swapl(&stuff->drawable, n); - swapl(&stuff->gc, n); + swapl(&stuff->drawable); + swapl(&stuff->gc); SwapRestS(stuff); return((* ProcVector[X_FillPoly])(client)); } @@ -698,16 +649,15 @@ SProcFillPoly(register ClientPtr client) int SProcPutImage(register ClientPtr client) { - register char n; REQUEST(xPutImageReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xPutImageReq); - swapl(&stuff->drawable, n); - swapl(&stuff->gc, n); - swaps(&stuff->width, n); - swaps(&stuff->height, n); - swaps(&stuff->dstX, n); - swaps(&stuff->dstY, n); + swapl(&stuff->drawable); + swapl(&stuff->gc); + swaps(&stuff->width); + swaps(&stuff->height); + swaps(&stuff->dstX); + swaps(&stuff->dstY); /* Image should already be swapped */ return((* ProcVector[X_PutImage])(client)); @@ -716,16 +666,15 @@ SProcPutImage(register ClientPtr client) int SProcGetImage(register ClientPtr client) { - register char n; REQUEST(xGetImageReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xGetImageReq); - swapl(&stuff->drawable, n); - swaps(&stuff->x, n); - swaps(&stuff->y, n); - swaps(&stuff->width, n); - swaps(&stuff->height, n); - swapl(&stuff->planeMask, n); + swapl(&stuff->drawable); + swaps(&stuff->x); + swaps(&stuff->y); + swaps(&stuff->width); + swaps(&stuff->height); + swapl(&stuff->planeMask); return((* ProcVector[X_GetImage])(client)); } @@ -734,14 +683,13 @@ SProcGetImage(register ClientPtr client) int SProcPolyText(register ClientPtr client) { - register char n; REQUEST(xPolyTextReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xPolyTextReq); - swapl(&stuff->drawable, n); - swapl(&stuff->gc, n); - swaps(&stuff->x, n); - swaps(&stuff->y, n); + swapl(&stuff->drawable); + swapl(&stuff->gc); + swaps(&stuff->x); + swaps(&stuff->y); return((* ProcVector[stuff->reqType])(client)); } @@ -750,27 +698,25 @@ SProcPolyText(register ClientPtr client) int SProcImageText(register ClientPtr client) { - register char n; REQUEST(xImageTextReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xImageTextReq); - swapl(&stuff->drawable, n); - swapl(&stuff->gc, n); - swaps(&stuff->x, n); - swaps(&stuff->y, n); + swapl(&stuff->drawable); + swapl(&stuff->gc); + swaps(&stuff->x); + swaps(&stuff->y); return((* ProcVector[stuff->reqType])(client)); } int SProcCreateColormap(register ClientPtr client) { - register char n; REQUEST(xCreateColormapReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xCreateColormapReq); - swapl(&stuff->mid, n); - swapl(&stuff->window, n); - swapl(&stuff->visual, n); + swapl(&stuff->mid); + swapl(&stuff->window); + swapl(&stuff->visual); return((* ProcVector[X_CreateColormap])(client)); } @@ -778,12 +724,11 @@ SProcCreateColormap(register ClientPtr client) int SProcCopyColormapAndFree(register ClientPtr client) { - register char n; REQUEST(xCopyColormapAndFreeReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xCopyColormapAndFreeReq); - swapl(&stuff->mid, n); - swapl(&stuff->srcCmap, n); + swapl(&stuff->mid); + swapl(&stuff->srcCmap); return((* ProcVector[X_CopyColormapAndFree])(client)); } @@ -791,67 +736,61 @@ SProcCopyColormapAndFree(register ClientPtr client) int SProcAllocColor(register ClientPtr client) { - register char n; REQUEST(xAllocColorReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xAllocColorReq); - swapl(&stuff->cmap, n); - swaps(&stuff->red, n); - swaps(&stuff->green, n); - swaps(&stuff->blue, n); + swapl(&stuff->cmap); + swaps(&stuff->red); + swaps(&stuff->green); + swaps(&stuff->blue); return((* ProcVector[X_AllocColor])(client)); } int SProcAllocNamedColor(register ClientPtr client) { - register char n; - REQUEST(xAllocNamedColorReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xAllocNamedColorReq); - swapl(&stuff->cmap, n); - swaps(&stuff->nbytes, n); + swapl(&stuff->cmap); + swaps(&stuff->nbytes); return((* ProcVector[X_AllocNamedColor])(client)); } int SProcAllocColorCells(register ClientPtr client) { - register char n; REQUEST(xAllocColorCellsReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xAllocColorCellsReq); - swapl(&stuff->cmap, n); - swaps(&stuff->colors, n); - swaps(&stuff->planes, n); + swapl(&stuff->cmap); + swaps(&stuff->colors); + swaps(&stuff->planes); return((* ProcVector[X_AllocColorCells])(client)); } int SProcAllocColorPlanes(register ClientPtr client) { - register char n; REQUEST(xAllocColorPlanesReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xAllocColorPlanesReq); - swapl(&stuff->cmap, n); - swaps(&stuff->colors, n); - swaps(&stuff->red, n); - swaps(&stuff->green, n); - swaps(&stuff->blue, n); + swapl(&stuff->cmap); + swaps(&stuff->colors); + swaps(&stuff->red); + swaps(&stuff->green); + swaps(&stuff->blue); return((* ProcVector[X_AllocColorPlanes])(client)); } int SProcFreeColors(register ClientPtr client) { - register char n; REQUEST(xFreeColorsReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xFreeColorsReq); - swapl(&stuff->cmap, n); - swapl(&stuff->planeMask, n); + swapl(&stuff->cmap); + swapl(&stuff->planeMask); SwapRestL(stuff); return((* ProcVector[X_FreeColors])(client)); @@ -860,25 +799,22 @@ SProcFreeColors(register ClientPtr client) void SwapColorItem(xColorItem *pItem) { - register char n; - - swapl(&pItem->pixel, n); - swaps(&pItem->red, n); - swaps(&pItem->green, n); - swaps(&pItem->blue, n); + swapl(&pItem->pixel); + swaps(&pItem->red); + swaps(&pItem->green); + swaps(&pItem->blue); } int SProcStoreColors(register ClientPtr client) { - register char n; long count; xColorItem *pItem; REQUEST(xStoreColorsReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xStoreColorsReq); - swapl(&stuff->cmap, n); + swapl(&stuff->cmap); pItem = (xColorItem *) &stuff[1]; for(count = LengthRestB(stuff)/sizeof(xColorItem); --count >= 0; ) SwapColorItem(pItem++); @@ -888,24 +824,22 @@ SProcStoreColors(register ClientPtr client) int SProcStoreNamedColor (register ClientPtr client) { - register char n; REQUEST(xStoreNamedColorReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xStoreNamedColorReq); - swapl(&stuff->cmap, n); - swapl(&stuff->pixel, n); - swaps(&stuff->nbytes, n); + swapl(&stuff->cmap); + swapl(&stuff->pixel); + swaps(&stuff->nbytes); return((* ProcVector[X_StoreNamedColor])(client)); } int SProcQueryColors (register ClientPtr client) { - register char n; REQUEST(xQueryColorsReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xQueryColorsReq); - swapl(&stuff->cmap, n); + swapl(&stuff->cmap); SwapRestL(stuff); return((* ProcVector[X_QueryColors])(client)); } @@ -913,54 +847,51 @@ SProcQueryColors (register ClientPtr client) int SProcLookupColor (register ClientPtr client) { - register char n; REQUEST(xLookupColorReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xLookupColorReq); - swapl(&stuff->cmap, n); - swaps(&stuff->nbytes, n); + swapl(&stuff->cmap); + swaps(&stuff->nbytes); return((* ProcVector[X_LookupColor])(client)); } int SProcCreateCursor (register ClientPtr client) { - register char n; REQUEST(xCreateCursorReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xCreateCursorReq); - swapl(&stuff->cid, n); - swapl(&stuff->source, n); - swapl(&stuff->mask, n); - swaps(&stuff->foreRed, n); - swaps(&stuff->foreGreen, n); - swaps(&stuff->foreBlue, n); - swaps(&stuff->backRed, n); - swaps(&stuff->backGreen, n); - swaps(&stuff->backBlue, n); - swaps(&stuff->x, n); - swaps(&stuff->y, n); + swapl(&stuff->cid); + swapl(&stuff->source); + swapl(&stuff->mask); + swaps(&stuff->foreRed); + swaps(&stuff->foreGreen); + swaps(&stuff->foreBlue); + swaps(&stuff->backRed); + swaps(&stuff->backGreen); + swaps(&stuff->backBlue); + swaps(&stuff->x); + swaps(&stuff->y); return((* ProcVector[X_CreateCursor])(client)); } int SProcCreateGlyphCursor (register ClientPtr client) { - register char n; REQUEST(xCreateGlyphCursorReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xCreateGlyphCursorReq); - swapl(&stuff->cid, n); - swapl(&stuff->source, n); - swapl(&stuff->mask, n); - swaps(&stuff->sourceChar, n); - swaps(&stuff->maskChar, n); - swaps(&stuff->foreRed, n); - swaps(&stuff->foreGreen, n); - swaps(&stuff->foreBlue, n); - swaps(&stuff->backRed, n); - swaps(&stuff->backGreen, n); - swaps(&stuff->backBlue, n); + swapl(&stuff->cid); + swapl(&stuff->source); + swapl(&stuff->mask); + swaps(&stuff->sourceChar); + swaps(&stuff->maskChar); + swaps(&stuff->foreRed); + swaps(&stuff->foreGreen); + swaps(&stuff->foreBlue); + swaps(&stuff->backRed); + swaps(&stuff->backGreen); + swaps(&stuff->backBlue); return((* ProcVector[X_CreateGlyphCursor])(client)); } @@ -968,30 +899,28 @@ SProcCreateGlyphCursor (register ClientPtr client) int SProcRecolorCursor (register ClientPtr client) { - register char n; REQUEST(xRecolorCursorReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xRecolorCursorReq); - swapl(&stuff->cursor, n); - swaps(&stuff->foreRed, n); - swaps(&stuff->foreGreen, n); - swaps(&stuff->foreBlue, n); - swaps(&stuff->backRed, n); - swaps(&stuff->backGreen, n); - swaps(&stuff->backBlue, n); + swapl(&stuff->cursor); + swaps(&stuff->foreRed); + swaps(&stuff->foreGreen); + swaps(&stuff->foreBlue); + swaps(&stuff->backRed); + swaps(&stuff->backGreen); + swaps(&stuff->backBlue); return((* ProcVector[X_RecolorCursor])(client)); } int SProcQueryBestSize (register ClientPtr client) { - register char n; REQUEST(xQueryBestSizeReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xQueryBestSizeReq); - swapl(&stuff->drawable, n); - swaps(&stuff->width, n); - swaps(&stuff->height, n); + swapl(&stuff->drawable); + swaps(&stuff->width); + swaps(&stuff->height); return((* ProcVector[X_QueryBestSize])(client)); } @@ -999,20 +928,18 @@ SProcQueryBestSize (register ClientPtr client) int SProcQueryExtension (register ClientPtr client) { - register char n; REQUEST(xQueryExtensionReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xQueryExtensionReq); - swaps(&stuff->nbytes, n); + swaps(&stuff->nbytes); return((* ProcVector[X_QueryExtension])(client)); } int SProcChangeKeyboardMapping (register ClientPtr client) { - register char n; REQUEST(xChangeKeyboardMappingReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xChangeKeyboardMappingReq); SwapRestL(stuff); return((* ProcVector[X_ChangeKeyboardMapping])(client)); @@ -1022,11 +949,10 @@ SProcChangeKeyboardMapping (register ClientPtr client) int SProcChangeKeyboardControl (register ClientPtr client) { - register char n; REQUEST(xChangeKeyboardControlReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xChangeKeyboardControlReq); - swapl(&stuff->mask, n); + swapl(&stuff->mask); SwapRestL(stuff); return((* ProcVector[X_ChangeKeyboardControl])(client)); } @@ -1034,13 +960,12 @@ SProcChangeKeyboardControl (register ClientPtr client) int SProcChangePointerControl (register ClientPtr client) { - register char n; REQUEST(xChangePointerControlReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xChangePointerControlReq); - swaps(&stuff->accelNum, n); - swaps(&stuff->accelDenum, n); - swaps(&stuff->threshold, n); + swaps(&stuff->accelNum); + swaps(&stuff->accelDenum); + swaps(&stuff->threshold); return((* ProcVector[X_ChangePointerControl])(client)); } @@ -1048,37 +973,33 @@ SProcChangePointerControl (register ClientPtr client) int SProcSetScreenSaver (register ClientPtr client) { - register char n; REQUEST(xSetScreenSaverReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_SIZE_MATCH(xSetScreenSaverReq); - swaps(&stuff->timeout, n); - swaps(&stuff->interval, n); + swaps(&stuff->timeout); + swaps(&stuff->interval); return((* ProcVector[X_SetScreenSaver])(client)); } int SProcChangeHosts (register ClientPtr client) { - register char n; - REQUEST(xChangeHostsReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xChangeHostsReq); - swaps(&stuff->hostLength, n); + swaps(&stuff->hostLength); return((* ProcVector[X_ChangeHosts])(client)); } int SProcRotateProperties (register ClientPtr client) { - register char n; REQUEST(xRotatePropertiesReq); - swaps(&stuff->length, n); + swaps(&stuff->length); REQUEST_AT_LEAST_SIZE(xRotatePropertiesReq); - swapl(&stuff->window, n); - swaps(&stuff->nAtoms, n); - swaps(&stuff->nPositions, n); + swapl(&stuff->window); + swaps(&stuff->nAtoms); + swaps(&stuff->nPositions); SwapRestL(stuff); return ((* ProcVector[X_RotateProperties])(client)); } @@ -1086,19 +1007,16 @@ int SProcRotateProperties (register ClientPtr client) int SProcNoOperation(register ClientPtr client) { - register char n; REQUEST(xReq); - swaps(&stuff->length, n); + swaps(&stuff->length); return ((* ProcVector[X_NoOperation])(client)); } void SwapConnClientPrefix(xConnClientPrefix *pCCP) { - register char n; - - swaps(&pCCP->majorVersion, n); - swaps(&pCCP->minorVersion, n); - swaps(&pCCP->nbytesAuthProto, n); - swaps(&pCCP->nbytesAuthString, n); + swaps(&pCCP->majorVersion); + swaps(&pCCP->minorVersion); + swaps(&pCCP->nbytesAuthProto); + swaps(&pCCP->nbytesAuthString); } |