diff options
Diffstat (limited to 'nx-X11/programs')
-rw-r--r-- | nx-X11/programs/Xserver/Xext/security.c | 3 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/Xext/xcmisc.c | 4 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/Xi/sendexev.c | 10 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/dbe/dbe.c | 7 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/dix/devices.c | 2 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/fb/fbbits.h | 2 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/hw/nxagent/Args.c | 4 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/hw/nxagent/Colormap.c | 2 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/hw/nxagent/Display.c | 2 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/hw/nxagent/Window.c | 2 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/xfixes/region.c | 2 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/xkb/xkb.c | 2 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/xkb/xkmread.c | 11 |
13 files changed, 25 insertions, 28 deletions
diff --git a/nx-X11/programs/Xserver/Xext/security.c b/nx-X11/programs/Xserver/Xext/security.c index 1071565f3..c1b7b50a9 100644 --- a/nx-X11/programs/Xserver/Xext/security.c +++ b/nx-X11/programs/Xserver/Xext/security.c @@ -148,7 +148,7 @@ int (*SwappedUntrustedProcVector[256])( * try a set of well known paths. */ -const char *_NXGetPolicyFilePath(const char *path) +char *_NXGetPolicyFilePath(const char *path) { struct stat SecurityPolicyStat; @@ -1345,7 +1345,6 @@ SecurityCensorImage(client, pVisibleRegion, widthBytesLine, pDraw, x, y, w, h, unsigned int format; char * pBuf; { - ScreenPtr pScreen = pDraw->pScreen; RegionRec imageRegion; /* region representing x,y,w,h */ RegionRec censorRegion; /* region to obliterate */ BoxRec imageBox; diff --git a/nx-X11/programs/Xserver/Xext/xcmisc.c b/nx-X11/programs/Xserver/Xext/xcmisc.c index 68843fd04..b7f55aa6d 100644 --- a/nx-X11/programs/Xserver/Xext/xcmisc.c +++ b/nx-X11/programs/Xserver/Xext/xcmisc.c @@ -40,11 +40,7 @@ from The Open Group. #include <nx-X11/extensions/xcmiscstr.h> #include "modinit.h" -#if HAVE_STDINT_H #include <stdint.h> -#elif !defined(UINT32_MAX) -#define UINT32_MAX 0xffffffffU -#endif #if 0 static unsigned char XCMiscCode; diff --git a/nx-X11/programs/Xserver/Xi/sendexev.c b/nx-X11/programs/Xserver/Xi/sendexev.c index 28286d97f..a851c5120 100644 --- a/nx-X11/programs/Xserver/Xi/sendexev.c +++ b/nx-X11/programs/Xserver/Xi/sendexev.c @@ -149,10 +149,14 @@ ProcXSendExtensionEvent (client) return Success; } - // FIXME: ret is not initialized and should not be returned... - + /* + the previous code here returned the unitialized variable ret, + so using Success we have defined returncode at least. FIXME: + Upstream works different here, we must check this! + */ if (stuff->num_events == 0) - return ret; + /* return ret; */ + return Success; /* The client's event type must be one defined by an extension. */ diff --git a/nx-X11/programs/Xserver/dbe/dbe.c b/nx-X11/programs/Xserver/dbe/dbe.c index 276919e34..58301e158 100644 --- a/nx-X11/programs/Xserver/dbe/dbe.c +++ b/nx-X11/programs/Xserver/dbe/dbe.c @@ -721,7 +721,7 @@ ProcDbeSwapBuffers(client) int error; unsigned int i, j; unsigned int nStuff; - + int nStuff_i; /* DDX API requires int for nStuff */ REQUEST_AT_LEAST_SIZE(xDbeSwapBuffersReq); nStuff = stuff->n; /* use local variable for performance. */ @@ -806,10 +806,11 @@ ProcDbeSwapBuffers(client) * could deal with cross-screen synchronization. */ - while (nStuff > 0) + nStuff_i = nStuff; + while (nStuff_i > 0) { pDbeScreenPriv = DBE_SCREEN_PRIV_FROM_WINDOW(swapInfo[0].pWindow); - error = (*pDbeScreenPriv->SwapBuffers)(client, &nStuff, swapInfo); + error = (*pDbeScreenPriv->SwapBuffers)(client, &nStuff_i, swapInfo); if (error != Success) { free(swapInfo); diff --git a/nx-X11/programs/Xserver/dix/devices.c b/nx-X11/programs/Xserver/dix/devices.c index 39f5d123f..69cdc82e1 100644 --- a/nx-X11/programs/Xserver/dix/devices.c +++ b/nx-X11/programs/Xserver/dix/devices.c @@ -725,7 +725,7 @@ InitStringFeedbackClassDeviceStruct ( for (i=0; i<num_symbols_supported; i++) *(feedc->ctrl.symbols_supported+i) = *symbols++; for (i=0; i<max_symbols; i++) - *(feedc->ctrl.symbols_displayed+i) = (KeySym) NULL; + *(feedc->ctrl.symbols_displayed+i) = (KeySym) 0; feedc->ctrl.id = 0; if ( (feedc->next = dev->stringfeed) ) feedc->ctrl.id = dev->stringfeed->ctrl.id + 1; diff --git a/nx-X11/programs/Xserver/fb/fbbits.h b/nx-X11/programs/Xserver/fb/fbbits.h index 5cd7ae70f..d915d7b35 100644 --- a/nx-X11/programs/Xserver/fb/fbbits.h +++ b/nx-X11/programs/Xserver/fb/fbbits.h @@ -829,8 +829,6 @@ POLYSEGMENT (DrawablePtr pDrawable, ul = coordToInt(pBox->x1 - xoff, pBox->y1 - yoff); lr = coordToInt(pBox->x2 - xoff - 1, pBox->y2 - yoff - 1); - bits += bitsStride * yoff + xoff * MUL; - capNotLast = pGC->capStyle == CapNotLast; while (nseg--) diff --git a/nx-X11/programs/Xserver/hw/nxagent/Args.c b/nx-X11/programs/Xserver/hw/nxagent/Args.c index 1c93bbbe5..7d256f5c5 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Args.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Args.c @@ -1447,7 +1447,7 @@ static void nxagentParseOptions(char *name, char *value) tolerance_parse = UINT_MAX; fprintf(stderr, "nxagentParseOptions: Warning: value [%s] of option [%s] " - "out of range, clamped to [%u].\n", + "out of range, clamped to [%lu].\n", validateString(value), validateString(name), tolerance_parse); } @@ -1456,7 +1456,7 @@ static void nxagentParseOptions(char *name, char *value) tolerance_parse = 0; fprintf(stderr, "nxagentParseOptions: Warning: value [%s] of option [%s] " - "out of range, clamped to [%u].\n", + "out of range, clamped to [%lu].\n", validateString(value), validateString(name), tolerance_parse); } diff --git a/nx-X11/programs/Xserver/hw/nxagent/Colormap.c b/nx-X11/programs/Xserver/hw/nxagent/Colormap.c index ecfbe210e..c21bcbbe7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Colormap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Colormap.c @@ -311,7 +311,7 @@ void nxagentSetInstalledColormapWindows(ScreenPtr pScreen) { fprintf(stderr, "nxagentSetInstalledColormapWindows: WARNING! " "Window at [%p] has no colormap with class [%d].\n", - pWin, pWin -> drawable.class); + (void *)pWin, pWin -> drawable.class); } #endif } diff --git a/nx-X11/programs/Xserver/hw/nxagent/Display.c b/nx-X11/programs/Xserver/hw/nxagent/Display.c index 04f2fbb4c..f1fb1e902 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Display.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Display.c @@ -2468,7 +2468,6 @@ static int nxagentCheckForPixmapFormatsCompatibility() */ bool compatible = true; - bool one_match = false; bool matched = false; int total_matches = 0; @@ -2483,7 +2482,6 @@ static int nxagentCheckForPixmapFormatsCompatibility() nxagentPixmapFormats[i].scanline_pad == nxagentRemotePixmapFormats[j].scanline_pad) { matched = true; - one_match = true; ++total_matches; break; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Window.c b/nx-X11/programs/Xserver/hw/nxagent/Window.c index e39afe240..f81e08ebc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Window.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Window.c @@ -1953,7 +1953,7 @@ Bool nxagentUnrealizeWindow(pWin) void nxagentFrameBufferPaintWindow(WindowPtr pWin, RegionPtr pRegion, int what) { - void *PaintWindowBackgroundBackup; + void (*PaintWindowBackgroundBackup)(WindowPtr, RegionPtr, int); if (pWin->backgroundState == BackgroundPixmap) { diff --git a/nx-X11/programs/Xserver/xfixes/region.c b/nx-X11/programs/Xserver/xfixes/region.c index 0b502c7f9..6759b4bfe 100644 --- a/nx-X11/programs/Xserver/xfixes/region.c +++ b/nx-X11/programs/Xserver/xfixes/region.c @@ -753,13 +753,11 @@ ProcXFixesSetPictureClipRegion (ClientPtr client) #ifdef RENDER PicturePtr pPicture; RegionPtr pRegion; - ScreenPtr pScreen; REQUEST(xXFixesSetPictureClipRegionReq); REQUEST_SIZE_MATCH (xXFixesSetPictureClipRegionReq); VERIFY_PICTURE(pPicture, stuff->picture, client, SecurityWriteAccess, RenderErrBase + BadPicture); - pScreen = pPicture->pDrawable->pScreen; VERIFY_REGION_OR_NONE(pRegion, stuff->region, client, SecurityReadAccess); return SetPictureClipRegion (pPicture, stuff->xOrigin, stuff->yOrigin, diff --git a/nx-X11/programs/Xserver/xkb/xkb.c b/nx-X11/programs/Xserver/xkb/xkb.c index 3e4cf4acd..a78541e75 100644 --- a/nx-X11/programs/Xserver/xkb/xkb.c +++ b/nx-X11/programs/Xserver/xkb/xkb.c @@ -4402,7 +4402,7 @@ char * wire, *next; CARD16 len; wire= *wire_inout; - len= (CARD16 *)wire; + len = *(CARD16 *) wire; if (client->swapped) { swaps(&len); } diff --git a/nx-X11/programs/Xserver/xkb/xkmread.c b/nx-X11/programs/Xserver/xkb/xkmread.c index 18ab21dca..1d8f6d772 100644 --- a/nx-X11/programs/Xserver/xkb/xkmread.c +++ b/nx-X11/programs/Xserver/xkb/xkmread.c @@ -1085,7 +1085,8 @@ unsigned i,size_toc; } return 0; } - fread(file_info,SIZEOF(xkmFileInfo),1,file); + _X_UNUSED int ignored_result; + ignored_result = fread(file_info,SIZEOF(xkmFileInfo),1,file); size_toc= file_info->num_toc; if (size_toc>max_toc) { #ifdef DEBUG @@ -1095,7 +1096,7 @@ unsigned i,size_toc; size_toc= max_toc; } for (i=0;i<size_toc;i++) { - fread(&toc[i],SIZEOF(xkmSectionInfo),1,file); + ignored_result = fread(&toc[i],SIZEOF(xkmSectionInfo),1,file); } return 1; } @@ -1126,7 +1127,8 @@ int nRead; return 0; } fseek(file,toc->offset,SEEK_SET); - fread(&tmpTOC,SIZEOF(xkmSectionInfo),1,file); + _X_UNUSED int ignored_result; + ignored_result = fread(&tmpTOC,SIZEOF(xkmSectionInfo),1,file); nRead= SIZEOF(xkmSectionInfo); if ((tmpTOC.type!=toc->type)||(tmpTOC.format!=toc->format)|| (tmpTOC.size!=toc->size)||(tmpTOC.offset!=toc->offset)) { @@ -1201,7 +1203,8 @@ char name[100]; case XkmSymbolsIndex: case XkmGeometryIndex: fseek(file,toc->offset,SEEK_SET); - fread(&tmpTOC,SIZEOF(xkmSectionInfo),1,file); + _X_UNUSED int ignored_result; + ignored_result = fread(&tmpTOC,SIZEOF(xkmSectionInfo),1,file); if ((tmpTOC.type!=toc->type)||(tmpTOC.format!=toc->format)|| (tmpTOC.size!=toc->size)||(tmpTOC.offset!=toc->offset)) { _XkbLibError(_XkbErrIllegalContents,"XkmReadFileSectionName",0); |