summaryrefslogtreecommitdiff
path: root/randr/rrinfo.c
diff options
context:
space:
mode:
authorMikhail Gusarov <dottedmag@dottedmag.net>2010-05-06 01:44:06 +0700
committerMikhail Gusarov <dottedmag@dottedmag.net>2010-05-13 00:22:37 +0700
commit3f3ff971ecff9936cebafc813af9193b97bba89c (patch)
treefdbbad794a42488b7ffe41eed7aba4e498335f55 /randr/rrinfo.c
parent96c7ab27c383ec767f62a7a11e5fd76f86363fbc (diff)
Replace X-allocation functions with their C89 counterparts
The only remaining X-functions used in server are XNF*, the rest is converted to plain alloc/calloc/realloc/free/strdup. X* functions are still exported from server and x* macros are still defined in header file, so both ABI and API are not affected by this change. Signed-off-by: Mikhail Gusarov <dottedmag@dottedmag.net> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'randr/rrinfo.c')
-rw-r--r--randr/rrinfo.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/randr/rrinfo.c b/randr/rrinfo.c
index 20066d5fc..fdf372607 100644
--- a/randr/rrinfo.c
+++ b/randr/rrinfo.c
@@ -55,10 +55,10 @@ RROldModeAdd (RROutputPtr output, RRScreenSizePtr size, int refresh)
}
if (output->numModes)
- modes = xrealloc (output->modes,
+ modes = realloc(output->modes,
(output->numModes + 1) * sizeof (RRModePtr));
else
- modes = xalloc (sizeof (RRModePtr));
+ modes = malloc(sizeof (RRModePtr));
if (!modes)
{
RRModeDestroy (mode);
@@ -134,7 +134,7 @@ RRScanOldConfig (ScreenPtr pScreen, Rotation rotations)
newMode = mode;
}
}
- xfree (size->pRates);
+ free(size->pRates);
}
else
{
@@ -144,7 +144,7 @@ RRScanOldConfig (ScreenPtr pScreen, Rotation rotations)
}
}
if (pScrPriv->nSizes)
- xfree (pScrPriv->pSizes);
+ free(pScrPriv->pSizes);
pScrPriv->pSizes = NULL;
pScrPriv->nSizes = 0;
@@ -279,7 +279,7 @@ RRRegisterSize (ScreenPtr pScreen,
for (i = 0; i < pScrPriv->nSizes; i++)
if (RRScreenSizeMatches (&tmp, &pScrPriv->pSizes[i]))
return &pScrPriv->pSizes[i];
- pNew = xrealloc (pScrPriv->pSizes,
+ pNew = realloc(pScrPriv->pSizes,
(pScrPriv->nSizes + 1) * sizeof (RRScreenSize));
if (!pNew)
return 0;
@@ -303,7 +303,7 @@ Bool RRRegisterRate (ScreenPtr pScreen,
if (pSize->pRates[i].rate == rate)
return TRUE;
- pNew = xrealloc (pSize->pRates,
+ pNew = realloc(pSize->pRates,
(pSize->nRates + 1) * sizeof (RRScreenRate));
if (!pNew)
return FALSE;