xnest/mi: remove redundant call of miScreenDevPrivateInit()

miScreenDevPrivateInit() is also made static in this commit.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/854>
This commit is contained in:
Tom Yan 2022-01-20 21:54:35 +08:00 committed by Alan Coopersmith
parent 786f7ceb61
commit aa3f5023e3
3 changed files with 4 additions and 11 deletions

View File

@ -242,8 +242,9 @@ xnestOpenScreen(ScreenPtr pScreen, int argc, char *argv[])
/* myNum */
/* id */
miScreenInit(pScreen, NULL, xnestWidth, xnestHeight, 1, 1, xnestWidth, rootDepth, numDepths, depths, defaultVisual, /* root visual */
numVisuals, visuals);
if (!miScreenInit(pScreen, NULL, xnestWidth, xnestHeight, 1, 1, xnestWidth, rootDepth, numDepths, depths, defaultVisual, /* root visual */
numVisuals, visuals))
return FALSE;
pScreen->defColormap = (Colormap) FakeClientID(0);
pScreen->minInstalledCmaps = MINCMAPS;
@ -332,9 +333,6 @@ xnestOpenScreen(ScreenPtr pScreen, int argc, char *argv[])
/* overwrite miCloseScreen with our own */
pScreen->CloseScreen = xnestCloseScreen;
if (!miScreenDevPrivateInit(pScreen, xnestWidth, NULL))
return FALSE;
/* overwrite miSetShape with our own */
pScreen->SetShape = xnestSetShape;

View File

@ -382,11 +382,6 @@ extern _X_EXPORT Bool miModifyPixmapHeader(PixmapPtr pPixmap,
extern _X_EXPORT Bool miCreateScreenResources(ScreenPtr /*pScreen */
);
extern _X_EXPORT Bool miScreenDevPrivateInit(ScreenPtr pScreen,
int width,
void *pbits
);
extern _X_EXPORT Bool miScreenInit(ScreenPtr pScreen,
void *pbits,
int xsize,

View File

@ -184,7 +184,7 @@ miCreateScreenResources(ScreenPtr pScreen)
return TRUE;
}
Bool
static Bool
miScreenDevPrivateInit(ScreenPtr pScreen, int width, void *pbits)
{
miScreenInitParmsPtr pScrInitParms;