diff options
author | Keith Packard <keithp@keithp.com> | 2013-12-15 01:05:51 -0800 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2014-01-12 10:24:11 -0800 |
commit | 60014a4a98ff924ae7f6840781f768c1cc93bbab (patch) | |
tree | a956a03a6a7c87cac4d48fb95b66fec313d87fde /mi | |
parent | 93fa64e17d7bd600ebf18ecab85f5b2d17fe30ce (diff) |
Replace 'pointer' type with 'void *'
This lets us stop using the 'pointer' typedef in Xdefs.h as 'pointer'
is used throughout the X server for other things, and having duplicate
names generates compiler warnings.
Signed-off-by: Keith Packard <keithp@keithp.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
Diffstat (limited to 'mi')
-rw-r--r-- | mi/mi.h | 10 | ||||
-rw-r--r-- | mi/miarc.c | 2 | ||||
-rw-r--r-- | mi/micmap.c | 2 | ||||
-rw-r--r-- | mi/midispcur.c | 6 | ||||
-rw-r--r-- | mi/miexpose.c | 2 | ||||
-rw-r--r-- | mi/migc.c | 8 | ||||
-rw-r--r-- | mi/migc.h | 2 | ||||
-rw-r--r-- | mi/miglblt.c | 4 | ||||
-rw-r--r-- | mi/mioverlay.c | 4 | ||||
-rw-r--r-- | mi/mipointer.c | 2 | ||||
-rw-r--r-- | mi/mipolyrect.c | 2 | ||||
-rw-r--r-- | mi/miscrinit.c | 16 | ||||
-rw-r--r-- | mi/misprite.c | 6 | ||||
-rw-r--r-- | mi/miwindow.c | 4 |
14 files changed, 35 insertions, 35 deletions
@@ -271,7 +271,7 @@ extern _X_EXPORT void miPolyGlyphBlt(DrawablePtr /*pDrawable */ , int /*y */ , unsigned int /*nglyph */ , CharInfoPtr * /*ppci */ , - pointer /*pglyphBase */ + void */*pglyphBase */ ); extern _X_EXPORT void miImageGlyphBlt(DrawablePtr /*pDrawable */ , @@ -280,7 +280,7 @@ extern _X_EXPORT void miImageGlyphBlt(DrawablePtr /*pDrawable */ , int /*y */ , unsigned int /*nglyph */ , CharInfoPtr * /*ppci */ , - pointer /*pglyphBase */ + void */*pglyphBase */ ); /* mipoly.c */ @@ -387,7 +387,7 @@ extern _X_EXPORT Bool miModifyPixmapHeader(PixmapPtr /*pPixmap */ , int /*depth */ , int /*bitsPerPixel */ , int /*devKind */ , - pointer /*pPixData */ + void */*pPixData */ ); extern _X_EXPORT Bool miCreateScreenResources(ScreenPtr /*pScreen */ @@ -395,11 +395,11 @@ extern _X_EXPORT Bool miCreateScreenResources(ScreenPtr /*pScreen */ extern _X_EXPORT Bool miScreenDevPrivateInit(ScreenPtr /*pScreen */ , int /*width */ , - pointer /*pbits */ + void */*pbits */ ); extern _X_EXPORT Bool miScreenInit(ScreenPtr /*pScreen */ , - pointer /*pbits */ , + void */*pbits */ , int /*xsize */ , int /*ysize */ , int /*dpix */ , diff --git a/mi/miarc.c b/mi/miarc.c index 0f6448bc1..0f56c7db3 100644 --- a/mi/miarc.c +++ b/mi/miarc.c @@ -1489,7 +1489,7 @@ miGetArcPts(SppArcPtr parc, /* points to an arc */ count++; cdt = 2 * miDcos(dt); - if (!(poly = (SppPointPtr) realloc((pointer) *ppPts, + if (!(poly = (SppPointPtr) realloc((void *) *ppPts, (cpt + count) * sizeof(SppPointRec)))) return 0; *ppPts = poly; diff --git a/mi/micmap.c b/mi/micmap.c index 3ef0c8c70..4648b9a70 100644 --- a/mi/micmap.c +++ b/mi/micmap.c @@ -75,7 +75,7 @@ miUninstallColormap(ColormapPtr pmap) if (pmap == curpmap) { if (pmap->mid != pmap->pScreen->defColormap) { - dixLookupResourceByType((pointer *) &curpmap, + dixLookupResourceByType((void **) &curpmap, pmap->pScreen->defColormap, RT_COLORMAP, serverClient, DixUseAccess); (*pmap->pScreen->InstallColormap) (curpmap); diff --git a/mi/midispcur.c b/mi/midispcur.c index edca9696f..8cca5fe6e 100644 --- a/mi/midispcur.c +++ b/mi/midispcur.c @@ -79,7 +79,7 @@ typedef struct { (miDCBufferPtr)dixLookupScreenPrivate(&GetMaster(dev, MASTER_POINTER)->devPrivates, miDCDeviceKey, screen)) /* - * The core pointer buffer will point to the index of the virtual core pointer + * The core pointer buffer will point to the index of the virtual pointer * in the pCursorBuffers array. */ typedef struct { @@ -114,7 +114,7 @@ miDCInitialize(ScreenPtr pScreen, miPointerScreenFuncPtr screenFuncs) dixSetPrivate(&pScreen->devPrivates, miDCScreenKey, pScreenPriv); if (!miSpriteInitialize(pScreen, screenFuncs)) { - free((pointer) pScreenPriv); + free((void *) pScreenPriv); return FALSE; } return TRUE; @@ -152,7 +152,7 @@ miDCCloseScreen(ScreenPtr pScreen) pScreen->CloseScreen = pScreenPriv->CloseScreen; miDCSwitchScreenCursor(pScreen, NULL, NULL, NULL, NULL); - free((pointer) pScreenPriv); + free((void *) pScreenPriv); return (*pScreen->CloseScreen) (pScreen); } diff --git a/mi/miexpose.c b/mi/miexpose.c index 8b7c93fb8..198c4332f 100644 --- a/mi/miexpose.c +++ b/mi/miexpose.c @@ -610,7 +610,7 @@ miPaintWindow(WindowPtr pWin, RegionPtr prgn, int what) gcmask |= GCPlaneMask; #endif gcval[c++].val = FillTiled; - gcval[c++].ptr = (pointer) fill.pixmap; + gcval[c++].ptr = (void *) fill.pixmap; gcval[c++].val = tile_x_off; gcval[c++].val = tile_y_off; gcmask |= GCFillStyle | GCTile | GCTileStipXOrigin | GCTileStipYOrigin; @@ -72,12 +72,12 @@ miDestroyClip(GCPtr pGC) } void -miChangeClip(GCPtr pGC, int type, pointer pvalue, int nrects) +miChangeClip(GCPtr pGC, int type, void *pvalue, int nrects) { (*pGC->funcs->DestroyClip) (pGC); if (type == CT_PIXMAP) { /* convert the pixmap to a region */ - pGC->clientClip = (pointer) BitmapToRegion(pGC->pScreen, + pGC->clientClip = (void *) BitmapToRegion(pGC->pScreen, (PixmapPtr) pvalue); (*pGC->pScreen->DestroyPixmap) (pvalue); } @@ -86,7 +86,7 @@ miChangeClip(GCPtr pGC, int type, pointer pvalue, int nrects) pGC->clientClip = pvalue; } else if (type != CT_NONE) { - pGC->clientClip = (pointer) RegionFromRects(nrects, + pGC->clientClip = (void *) RegionFromRects(nrects, (xRectangle *) pvalue, type); free(pvalue); @@ -112,7 +112,7 @@ miCopyClip(GCPtr pgcDst, GCPtr pgcSrc) case CT_REGION: prgnNew = RegionCreate(NULL, 1); RegionCopy(prgnNew, (RegionPtr) (pgcSrc->clientClip)); - (*pgcDst->funcs->ChangeClip) (pgcDst, CT_REGION, (pointer) prgnNew, 0); + (*pgcDst->funcs->ChangeClip) (pgcDst, CT_REGION, (void *) prgnNew, 0); break; } } @@ -38,7 +38,7 @@ extern _X_EXPORT void miDestroyClip(GCPtr /*pGC */ extern _X_EXPORT void miChangeClip(GCPtr /*pGC */ , int /*type */ , - pointer /*pvalue */ , + void */*pvalue */ , int /*nrects */ ); diff --git a/mi/miglblt.c b/mi/miglblt.c index 1a70911fa..b53ab9c0e 100644 --- a/mi/miglblt.c +++ b/mi/miglblt.c @@ -81,7 +81,7 @@ with the sample server. void miPolyGlyphBlt(DrawablePtr pDrawable, GC * pGC, int x, int y, unsigned int nglyph, CharInfoPtr * ppci, /* array of character info */ - pointer pglyphBase /* start of array of glyphs */ + void *pglyphBase /* start of array of glyphs */ ) { int width, height; @@ -182,7 +182,7 @@ miPolyGlyphBlt(DrawablePtr pDrawable, GC * pGC, int x, int y, unsigned int nglyp void miImageGlyphBlt(DrawablePtr pDrawable, GC * pGC, int x, int y, unsigned int nglyph, CharInfoPtr * ppci, /* array of character info */ - pointer pglyphBase /* start of array of glyphs */ + void *pglyphBase /* start of array of glyphs */ ) { ExtentInfoRec info; /* used by QueryGlyphExtents() */ diff --git a/mi/mioverlay.c b/mi/mioverlay.c index 2bfd5e401..7f502fa37 100644 --- a/mi/mioverlay.c +++ b/mi/mioverlay.c @@ -1050,7 +1050,7 @@ typedef struct { } miOverlayTwoRegions; static int -miOverlayRecomputeExposures(WindowPtr pWin, pointer value) +miOverlayRecomputeExposures(WindowPtr pWin, void *value) { miOverlayTwoRegions *pValid = (miOverlayTwoRegions *) value; miOverlayTreePtr pTree = MIOVERLAY_GET_WINDOW_TREE(pWin); @@ -1404,7 +1404,7 @@ miOverlayResizeWindow(WindowPtr pWin, TwoRegions.under = gravitate2[g]; TraverseTree(pChild, miOverlayRecomputeExposures, - (pointer) (&TwoRegions)); + (void *) (&TwoRegions)); } /* diff --git a/mi/mipointer.c b/mi/mipointer.c index df027a716..6fa416d9d 100644 --- a/mi/mipointer.c +++ b/mi/mipointer.c @@ -152,7 +152,7 @@ miPointerCloseScreen(ScreenPtr pScreen) SetupScreen(pScreen); pScreen->CloseScreen = pScreenPriv->CloseScreen; - free((pointer) pScreenPriv); + free((void *) pScreenPriv); FreeEventList(mipointermove_events, GetMaximumEventsNum()); mipointermove_events = NULL; return (*pScreen->CloseScreen) (pScreen); diff --git a/mi/mipolyrect.c b/mi/mipolyrect.c index a0e88d2f2..e316ae053 100644 --- a/mi/mipolyrect.c +++ b/mi/mipolyrect.c @@ -148,7 +148,7 @@ miPolyRectangle(DrawablePtr pDraw, GCPtr pGC, int nrects, xRectangle *pRects) } } (*pGC->ops->PolyFillRect) (pDraw, pGC, t - tmp, tmp); - free((pointer) tmp); + free((void *) tmp); } else { diff --git a/mi/miscrinit.c b/mi/miscrinit.c index 4698b532f..6aed52f51 100644 --- a/mi/miscrinit.c +++ b/mi/miscrinit.c @@ -53,14 +53,14 @@ from The Open Group. */ typedef struct { - pointer pbits; /* pointer to framebuffer */ + void *pbits; /* pointer to framebuffer */ int width; /* delta to add to a framebuffer addr to move one row down */ } miScreenInitParmsRec, *miScreenInitParmsPtr; /* this plugs into pScreen->ModifyPixmapHeader */ Bool miModifyPixmapHeader(PixmapPtr pPixmap, int width, int height, int depth, - int bitsPerPixel, int devKind, pointer pPixData) + int bitsPerPixel, int devKind, void *pPixData) { if (!pPixmap) return FALSE; @@ -135,7 +135,7 @@ Bool miCreateScreenResources(ScreenPtr pScreen) { miScreenInitParmsPtr pScrInitParms; - pointer value; + void *value; pScrInitParms = (miScreenInitParmsPtr) pScreen->devPrivate; @@ -161,7 +161,7 @@ miCreateScreenResources(ScreenPtr pScreen) pScreen->rootDepth), pScrInitParms->pbits)) return FALSE; - value = (pointer) pPixmap; + value = (void *) pPixmap; } else { value = pScrInitParms->pbits; @@ -172,7 +172,7 @@ miCreateScreenResources(ScreenPtr pScreen) } Bool -miScreenDevPrivateInit(ScreenPtr pScreen, int width, pointer pbits) +miScreenDevPrivateInit(ScreenPtr pScreen, int width, void *pbits) { miScreenInitParmsPtr pScrInitParms; @@ -185,7 +185,7 @@ miScreenDevPrivateInit(ScreenPtr pScreen, int width, pointer pbits) return FALSE; pScrInitParms->pbits = pbits; pScrInitParms->width = width; - pScreen->devPrivate = (pointer) pScrInitParms; + pScreen->devPrivate = (void *) pScrInitParms; return TRUE; } @@ -199,11 +199,11 @@ static void miSetScreenPixmap(PixmapPtr pPix) { if (pPix) - pPix->drawable.pScreen->devPrivate = (pointer) pPix; + pPix->drawable.pScreen->devPrivate = (void *) pPix; } Bool -miScreenInit(ScreenPtr pScreen, pointer pbits, /* pointer to screen bits */ +miScreenInit(ScreenPtr pScreen, void *pbits, /* pointer to screen bits */ int xsize, int ysize, /* in pixels */ int dpix, int dpiy, /* dots per inch */ int width, /* pixel width of frame buffer */ diff --git a/mi/misprite.c b/mi/misprite.c index 85ca022ed..eea731a15 100644 --- a/mi/misprite.c +++ b/mi/misprite.c @@ -199,7 +199,7 @@ static void miSpriteSourceValidate(DrawablePtr pDrawable, int x, int y, static void miSpriteCopyWindow(WindowPtr pWindow, DDXPointRec ptOldOrg, RegionPtr prgnSrc); static void miSpriteBlockHandler(ScreenPtr pScreen, - pointer pTimeout, pointer pReadMask); + void *pTimeout, void *pReadMask); static void miSpriteInstallColormap(ColormapPtr pMap); static void miSpriteStoreColors(ColormapPtr pMap, int ndef, xColorItem * pdef); @@ -512,8 +512,8 @@ miSpriteCopyWindow(WindowPtr pWindow, DDXPointRec ptOldOrg, RegionPtr prgnSrc) } static void -miSpriteBlockHandler(ScreenPtr pScreen, pointer pTimeout, - pointer pReadmask) +miSpriteBlockHandler(ScreenPtr pScreen, void *pTimeout, + void *pReadmask) { miSpriteScreenPtr pPriv = GetSpriteScreen(pScreen); DeviceIntPtr pDev; diff --git a/mi/miwindow.c b/mi/miwindow.c index 8dd99dbf0..697ffbc26 100644 --- a/mi/miwindow.c +++ b/mi/miwindow.c @@ -305,7 +305,7 @@ miMoveWindow(WindowPtr pWin, int x, int y, WindowPtr pNextSib, VTKind kind) */ static int -miRecomputeExposures(WindowPtr pWin, pointer value) +miRecomputeExposures(WindowPtr pWin, void *value) { /* must conform to VisitWindowProcPtr */ RegionPtr pValid = (RegionPtr) value; @@ -584,7 +584,7 @@ miSlideAndSizeWindow(WindowPtr pWin, if (pChild->winGravity != g) continue; RegionIntersect(pRegion, &pChild->borderClip, gravitate[g]); - TraverseTree(pChild, miRecomputeExposures, (pointer) pRegion); + TraverseTree(pChild, miRecomputeExposures, (void *) pRegion); } /* |