From 994f7a1c814a89e90f710dac5bf6b2445fb64712 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Wed, 29 Jul 2009 12:11:13 +1000 Subject: record: silence some compiler warnings. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit warning: passing argument 4 of ‘RecordAProtocolElement’ discards qualifiers from pointer target type note: expected ‘pointer’ but argument is of type ‘const void *’ record.c:2745: warning: passing argument 1 of ‘SwapConnSetupInfo’ from incompatible pointer type ../include/swaprep.h:243: note: expected ‘char *’ but argument is of type ‘struct xConnSetup *’ record.c:2745: warning: passing argument 1 of ‘SwapConnSetupInfo’ from incompatible pointer type ../include/swaprep.h:243: note: expected ‘char *’ but argument is of type ‘struct xConnSetup *’ Signed-off-by: Peter Hutterer --- record/record.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'record') diff --git a/record/record.c b/record/record.c index effb9263d..7000b00e2 100644 --- a/record/record.c +++ b/record/record.c @@ -614,7 +614,7 @@ RecordAReply(CallbackListPtr *pcbl, pointer nulldata, pointer calldata) if (pContext->continuedReply) { RecordAProtocolElement(pContext, client, XRecordFromServer, - pri->replyData, pri->dataLenBytes, /* continuation */ -1); + (pointer)pri->replyData, pri->dataLenBytes, /* continuation */ -1); if (!pri->bytesRemaining) pContext->continuedReply = 0; } @@ -624,7 +624,7 @@ RecordAReply(CallbackListPtr *pcbl, pointer nulldata, pointer calldata) if (majorop <= 127) { /* core reply */ RecordAProtocolElement(pContext, client, XRecordFromServer, - pri->replyData, pri->dataLenBytes, pri->bytesRemaining); + (pointer)pri->replyData, pri->dataLenBytes, pri->bytesRemaining); if (pri->bytesRemaining) pContext->continuedReply = 1; } @@ -645,7 +645,7 @@ RecordAReply(CallbackListPtr *pcbl, pointer nulldata, pointer calldata) minorop)) { RecordAProtocolElement(pContext, client, - XRecordFromServer, pri->replyData, + XRecordFromServer, (pointer)pri->replyData, pri->dataLenBytes, pri->bytesRemaining); if (pri->bytesRemaining) pContext->continuedReply = 1; @@ -2741,8 +2741,8 @@ RecordConnectionSetupInfo(RecordContextPtr pContext, NewClientInfoRec *pci) char *pConnSetup = (char *)xalloc(prefixsize + restsize); if (!pConnSetup) return; - SwapConnSetupPrefix(pci->prefix, pConnSetup); - SwapConnSetupInfo(pci->setup, pConnSetup + prefixsize); + SwapConnSetupPrefix(pci->prefix, (xConnSetupPrefix*)pConnSetup); + SwapConnSetupInfo((char*)pci->setup, (char*)(pConnSetup + prefixsize)); RecordAProtocolElement(pContext, pci->client, XRecordClientStarted, (pointer)pConnSetup, prefixsize + restsize, 0); xfree(pConnSetup); -- cgit v1.2.3