diff options
Diffstat (limited to 'xorg-server/hw/dmx/dmxgc.c')
-rw-r--r-- | xorg-server/hw/dmx/dmxgc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/xorg-server/hw/dmx/dmxgc.c b/xorg-server/hw/dmx/dmxgc.c index ec15d27aa..c4789a607 100644 --- a/xorg-server/hw/dmx/dmxgc.c +++ b/xorg-server/hw/dmx/dmxgc.c @@ -397,7 +397,7 @@ dmxChangeClip(GCPtr pGC, int type, void *pvalue, int nrects) } else { if (dmxScreen->beDisplay) { nRects = RegionNumRects((RegionPtr) pGC->clientClip); - pRects = malloc(nRects * sizeof(*pRects)); + pRects = xallocarray(nRects, sizeof(*pRects)); pBox = RegionRects((RegionPtr) pGC->clientClip); for (i = 0; i < nRects; i++) { |