diff options
author | glebius <glebius@FreeBSD.org> | 2016-01-11 01:09:50 +0000 |
---|---|---|
committer | glebius <glebius@FreeBSD.org> | 2016-01-11 01:09:50 +0000 |
commit | c41fbaf9bc76f0b7650e448fbd88d0a9815f47fd (patch) | |
tree | 3b45c8e63a37b132f0fe10c570b8302052c547de /contrib/ntp/ntpdate | |
parent | 3066f138bc3bf99f5cf6ec9412903d206c329cc7 (diff) | |
download | FreeBSD-src-c41fbaf9bc76f0b7650e448fbd88d0a9815f47fd.zip FreeBSD-src-c41fbaf9bc76f0b7650e448fbd88d0a9815f47fd.tar.gz |
Merge r293423, r293469:
ntp 4.2.8p5
Relnotes: yes
Diffstat (limited to 'contrib/ntp/ntpdate')
-rw-r--r-- | contrib/ntp/ntpdate/ntpdate.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/contrib/ntp/ntpdate/ntpdate.c b/contrib/ntp/ntpdate/ntpdate.c index 9831929..a427160 100644 --- a/contrib/ntp/ntpdate/ntpdate.c +++ b/contrib/ntp/ntpdate/ntpdate.c @@ -561,8 +561,8 @@ ntpdatemain ( nfound = poll(rdfdes, (unsigned int)nbsock, timeout.tv_sec * 1000); #else - nfound = select(maxfd, &rdfdes, (fd_set *)0, - (fd_set *)0, &timeout); + nfound = select(maxfd, &rdfdes, NULL, NULL, + &timeout); #endif if (nfound > 0) input_handler(); @@ -696,7 +696,7 @@ transmit( * If not, just timestamp it and send it away. */ if (sys_authenticate) { - int len; + size_t len; xpkt.exten[0] = htonl(sys_authkey); get_systime(&server->xmt); @@ -808,11 +808,11 @@ receive( printf("receive: rpkt keyid=%ld sys_authkey=%ld decrypt=%ld\n", (long int)ntohl(rpkt->exten[0]), (long int)sys_authkey, (long int)authdecrypt(sys_authkey, (u_int32 *)rpkt, - LEN_PKT_NOMAC, (int)(rbufp->recv_length - LEN_PKT_NOMAC))); + LEN_PKT_NOMAC, (size_t)(rbufp->recv_length - LEN_PKT_NOMAC))); if (has_mac && ntohl(rpkt->exten[0]) == sys_authkey && authdecrypt(sys_authkey, (u_int32 *)rpkt, LEN_PKT_NOMAC, - (int)(rbufp->recv_length - LEN_PKT_NOMAC))) + (size_t)(rbufp->recv_length - LEN_PKT_NOMAC))) is_authentic = 1; if (debug) printf("receive: authentication %s\n", @@ -1888,7 +1888,7 @@ input_handler(void) #else fd_set fds; #endif - int fdc = 0; + SOCKET fdc = 0; /* * Do a poll to see if we have data @@ -1912,7 +1912,7 @@ input_handler(void) #else fds = fdmask; - n = select(maxfd, &fds, (fd_set *)0, (fd_set *)0, &tvzero); + n = select(maxfd, &fds, NULL, NULL, &tvzero); /* * Determine which socket received data |