From 4ddb002b6847e8a88e6f13ae0453a35ee79946ae Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Mon, 15 Jun 2009 15:14:47 +1000 Subject: xfree86: fix two compiler warnings in xf86vmode.c MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit xf86vmode.c:1578: warning: pointer targets in passing argument 1 of ‘SwapShorts’ differ in signedness ../../../../include/misc.h:231: note: expected ‘short int *’ but argument is of type ‘CARD16 *’ xf86vmode.c:1543: warning: unused variable ‘i’ Signed-off-by: Peter Hutterer --- hw/xfree86/dixmods/extmod/xf86vmode.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'hw') diff --git a/hw/xfree86/dixmods/extmod/xf86vmode.c b/hw/xfree86/dixmods/extmod/xf86vmode.c index 10b9ed370..bd6c59462 100644 --- a/hw/xfree86/dixmods/extmod/xf86vmode.c +++ b/hw/xfree86/dixmods/extmod/xf86vmode.c @@ -1540,7 +1540,7 @@ static int ProcXF86VidModeGetGammaRamp(ClientPtr client) { CARD16 *ramp = NULL; - int n, length, i; + int n, length; size_t ramplen; xXF86VidModeGetGammaRampReply rep; REQUEST(xXF86VidModeGetGammaRampReq); @@ -1575,7 +1575,7 @@ ProcXF86VidModeGetGammaRamp(ClientPtr client) swaps(&rep.sequenceNumber, n); swapl(&rep.length, n); swaps(&rep.size, n); - SwapShorts(ramp, length * 3); + SwapShorts((short*)ramp, length * 3); } WriteToClient(client, sizeof(xXF86VidModeGetGammaRampReply), (char *)&rep); -- cgit v1.2.3