aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw/xwin/wincursor.c
diff options
context:
space:
mode:
Diffstat (limited to 'xorg-server/hw/xwin/wincursor.c')
-rw-r--r--xorg-server/hw/xwin/wincursor.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/xorg-server/hw/xwin/wincursor.c b/xorg-server/hw/xwin/wincursor.c
index a35336a34..f3ac0f7ae 100644
--- a/xorg-server/hw/xwin/wincursor.c
+++ b/xorg-server/hw/xwin/wincursor.c
@@ -255,10 +255,8 @@ winLoadCursor(ScreenPtr pScreen, CursorPtr pCursor, int screen)
bi.bV4BlueMask = 0x000000FF;
bi.bV4AlphaMask = 0xFF000000;
- lpBits =
- (uint32_t *) calloc(pScreenPriv->cursor.sm_cx *
- pScreenPriv->cursor.sm_cy,
- sizeof(uint32_t));
+ lpBits = calloc(pScreenPriv->cursor.sm_cx * pScreenPriv->cursor.sm_cy,
+ sizeof(uint32_t));
if (lpBits) {
int y;
@@ -302,9 +300,7 @@ winLoadCursor(ScreenPtr pScreen, CursorPtr pCursor, int screen)
pbmiColors[2].rgbBlue = pCursor->foreBlue >> 8;
pbmiColors[2].rgbReserved = 0;
- lpBits =
- (uint32_t *) calloc(pScreenPriv->cursor.sm_cx *
- pScreenPriv->cursor.sm_cy, sizeof(char));
+ lpBits = calloc(pScreenPriv->cursor.sm_cx * pScreenPriv->cursor.sm_cy, 1);
pCur = (unsigned char *) lpBits;
if (lpBits) {