aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/programs/Xserver/os
diff options
context:
space:
mode:
authorMike Gabriel <mike.gabriel@das-netzwerkteam.de>2016-07-05 13:34:26 +0200
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2016-07-05 13:34:26 +0200
commit381706aa279799201d5750bb971cac91e05db995 (patch)
tree13abc7de22c00d7ab9080c47df749afbe94d8f85 /nx-X11/programs/Xserver/os
parent06a97857a0380f88b691ac022fa30a05d54e43e0 (diff)
parentf6a1bda2dff0c70aa13f3cb763a9b08c4c037c53 (diff)
downloadnx-libs-381706aa279799201d5750bb971cac91e05db995.tar.gz
nx-libs-381706aa279799201d5750bb971cac91e05db995.tar.bz2
nx-libs-381706aa279799201d5750bb971cac91e05db995.zip
Merge branch 'sunweaver-pr/no-more-type-casting-in-writetoclient' into 3.6.x
Attributes GH PR #178: https://github.com/ArcticaProject/nx-libs/pull/178 Reviewed by: Vadim Troshchinskiy <vadim@qindel.com> -- Tue, 05 Jul 2016 02:37:08 -0700
Diffstat (limited to 'nx-X11/programs/Xserver/os')
-rw-r--r--nx-X11/programs/Xserver/os/io.c8
-rw-r--r--nx-X11/programs/Xserver/os/osdep.h2
-rw-r--r--nx-X11/programs/Xserver/os/secauth.c2
3 files changed, 7 insertions, 5 deletions
diff --git a/nx-X11/programs/Xserver/os/io.c b/nx-X11/programs/Xserver/os/io.c
index 4d12c6e89..470d1bec2 100644
--- a/nx-X11/programs/Xserver/os/io.c
+++ b/nx-X11/programs/Xserver/os/io.c
@@ -857,11 +857,12 @@ SetCriticalOutputPending(void)
*****************/
int
-WriteToClient (ClientPtr who, int count, char *buf)
+WriteToClient (ClientPtr who, int count, const void *__buf)
{
OsCommPtr oc;
ConnectionOutputPtr oco;
int padBytes;
+ const char *buf = __buf;
#ifdef DEBUG_COMMUNICATION
Bool multicount = FALSE;
#endif
@@ -999,13 +1000,14 @@ WriteToClient (ClientPtr who, int count, char *buf)
**********************/
int
-FlushClient(ClientPtr who, OsCommPtr oc, char *extraBuf, int extraCount)
+FlushClient(ClientPtr who, OsCommPtr oc, const void *__extraBuf, int extraCount)
{
ConnectionOutputPtr oco = oc->output;
int connection = oc->fd;
XtransConnInfo trans_conn = oc->trans_conn;
struct iovec iov[3];
static char padBuffer[3];
+ const char *extraBuf = __extraBuf;
long written;
long padsize;
long notWritten;
@@ -1051,7 +1053,7 @@ FlushClient(ClientPtr who, OsCommPtr oc, char *extraBuf, int extraCount)
}
InsertIOV ((char *)oco->buf, oco->count)
- InsertIOV (extraBuf, extraCount)
+ InsertIOV ((char *)extraBuf, extraCount)
InsertIOV (padBuffer, padsize)
errno = 0;
diff --git a/nx-X11/programs/Xserver/os/osdep.h b/nx-X11/programs/Xserver/os/osdep.h
index 633039f4a..a13af57d5 100644
--- a/nx-X11/programs/Xserver/os/osdep.h
+++ b/nx-X11/programs/Xserver/os/osdep.h
@@ -187,7 +187,7 @@ typedef struct _osComm {
extern int FlushClient(
ClientPtr /*who*/,
OsCommPtr /*oc*/,
- char* /*extraBuf*/,
+ const void * /*__extraBuf*/,
int /*extraCount*/
);
diff --git a/nx-X11/programs/Xserver/os/secauth.c b/nx-X11/programs/Xserver/os/secauth.c
index eadb17b40..735afd6e5 100644
--- a/nx-X11/programs/Xserver/os/secauth.c
+++ b/nx-X11/programs/Xserver/os/secauth.c
@@ -181,7 +181,7 @@ AuthSecurityCheck (
if (client->swapped)
WriteSConnSetupPrefix(client, &csp);
else
- (void)WriteToClient(client, sz_xConnSetupPrefix, (char *) &csp);
+ WriteToClient(client, sz_xConnSetupPrefix, &csp);
/*
* Next time the client sends the real auth data, we want