From 132b464d734b077038e19b21e46d3a6258f4b998 Mon Sep 17 00:00:00 2001 From: Adam Jackson Date: Thu, 22 Jan 2009 02:11:16 -0500 Subject: Remove a bunch of useless casts. We've had void * for twenty years now people let's try to act like we know how it works. --- os/io.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'os/io.c') diff --git a/os/io.c b/os/io.c index 88215e2f0..45e193801 100644 --- a/os/io.c +++ b/os/io.c @@ -1011,14 +1011,14 @@ AllocateInputBuffer(void) { ConnectionInputPtr oci; - oci = (ConnectionInputPtr)xalloc(sizeof(ConnectionInput)); + oci = xalloc(sizeof(ConnectionInput)); if (!oci) - return (ConnectionInputPtr)NULL; - oci->buffer = (char *)xalloc(BUFSIZE); + return NULL; + oci->buffer = xalloc(BUFSIZE); if (!oci->buffer) { xfree(oci); - return (ConnectionInputPtr)NULL; + return NULL; } oci->size = BUFSIZE; oci->bufptr = oci->buffer; @@ -1032,14 +1032,14 @@ AllocateOutputBuffer(void) { ConnectionOutputPtr oco; - oco = (ConnectionOutputPtr)xalloc(sizeof(ConnectionOutput)); + oco = xalloc(sizeof(ConnectionOutput)); if (!oco) - return (ConnectionOutputPtr)NULL; - oco->buf = (unsigned char *) xcalloc(1, BUFSIZE); + return NULL; + oco->buf = xcalloc(1, BUFSIZE); if (!oco->buf) { xfree(oco); - return (ConnectionOutputPtr)NULL; + return NULL; } oco->size = BUFSIZE; oco->count = 0; -- cgit v1.2.3