From: Guy Harris Date: Thu, 13 Sep 2018 06:51:05 +0000 (-0700) Subject: Squelch some shortening warnings. X-Git-Tag: libpcap-1.10-bp~831 X-Git-Url: https://git.tcpdump.org/libpcap/commitdiff_plain/0d3e1f33ca7cdc0370a688184aec266c24ab1660 Squelch some shortening warnings. --- diff --git a/rpcapd/daemon.c b/rpcapd/daemon.c index 4502e084..4d8d7349 100644 --- a/rpcapd/daemon.c +++ b/rpcapd/daemon.c @@ -213,7 +213,7 @@ daemon_serviceloop(SOCKET sockctrl_in, SOCKET sockctrl_out, int isactive, int nu FD_SET(pars.sockctrl_in, &rfds); - retval = select(pars.sockctrl_in + 1, &rfds, NULL, NULL, &tv); + retval = select((int)pars.sockctrl_in + 1, &rfds, NULL, NULL, &tv); if (retval == -1) { sock_geterror("select failed: ", errmsgbuf, PCAP_ERRBUF_SIZE); @@ -492,7 +492,7 @@ daemon_serviceloop(SOCKET sockctrl_in, SOCKET sockctrl_out, int isactive, int nu FD_SET(pars.sockctrl_in, &rfds); - retval = select(pars.sockctrl_in + 1, &rfds, NULL, NULL, &tv); + retval = select((int)pars.sockctrl_in + 1, &rfds, NULL, NULL, &tv); if (retval == -1) { sock_geterror("select failed: ", errmsgbuf, PCAP_ERRBUF_SIZE); diff --git a/sockutils.c b/sockutils.c index e01bd967..d2ceaaba 100644 --- a/sockutils.c +++ b/sockutils.c @@ -955,7 +955,7 @@ int sock_recv_dgram(SOCKET sock, void *buffer, size_t size, * don't need to loop. */ #ifdef _WIN32 - nread = recv(sock, buffer, size, 0); + nread = recv(sock, buffer, (int)size, 0); if (nread == SOCKET_ERROR) { /*