Fix some warnings discovered by compiling the unixsim under cygwin (gcc pedantic)

This commit is contained in:
goldsimon
2007-11-25 13:57:05 +00:00
parent 1b208d0954
commit e1f49d990b
5 changed files with 13 additions and 13 deletions

View File

@@ -469,7 +469,7 @@ lwip_recvfrom(int s, void *mem, int len, unsigned int flags,
return -1;
do {
LWIP_DEBUGF(SOCKETS_DEBUG, ("lwip_recvfrom: top while sock->lastdata=%p\n", sock->lastdata));
LWIP_DEBUGF(SOCKETS_DEBUG, ("lwip_recvfrom: top while sock->lastdata=%p\n", (void*)sock->lastdata));
/* Check if there is data left from the last recv operation. */
if (sock->lastdata) {
buf = sock->lastdata;
@@ -484,7 +484,7 @@ lwip_recvfrom(int s, void *mem, int len, unsigned int flags,
/* No data was left from the previous operation, so we try to get
some from the network. */
sock->lastdata = buf = netconn_recv(sock->conn);
LWIP_DEBUGF(SOCKETS_DEBUG, ("lwip_recvfrom: netconn_recv netbuf=%p\n", buf));
LWIP_DEBUGF(SOCKETS_DEBUG, ("lwip_recvfrom: netconn_recv netbuf=%p\n", (void*)buf));
if (!buf) {
/* We should really do some error checking here. */
@@ -528,11 +528,11 @@ lwip_recvfrom(int s, void *mem, int len, unsigned int flags,
if ((sock->conn->type == NETCONN_TCP) && (buflen - copylen > 0)) {
sock->lastdata = buf;
sock->lastoffset += copylen;
LWIP_DEBUGF(SOCKETS_DEBUG, ("lwip_recvfrom: lastdata now netbuf=%p\n", buf));
LWIP_DEBUGF(SOCKETS_DEBUG, ("lwip_recvfrom: lastdata now netbuf=%p\n", (void*)buf));
} else {
sock->lastdata = NULL;
sock->lastoffset = 0;
LWIP_DEBUGF(SOCKETS_DEBUG, ("lwip_recvfrom: deleting netbuf=%p\n", buf));
LWIP_DEBUGF(SOCKETS_DEBUG, ("lwip_recvfrom: deleting netbuf=%p\n", (void*)buf));
netbuf_delete(buf);
}
} else {