summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfgsch <fgsch@openbsd.org>2000-10-08 02:47:00 +0000
committerfgsch <fgsch@openbsd.org>2000-10-08 02:47:00 +0000
commitb78916e41217f0735c2073c22c5c0112518f909e (patch)
tree8d9178385dc7bd5199c74bca036888751381f7e2
parentupdate DNS label length validation. check inet_ntop() errors. sync with kame. (diff)
downloadwireguard-openbsd-b78916e41217f0735c2073c22c5c0112518f909e.tar.xz
wireguard-openbsd-b78916e41217f0735c2073c22c5c0112518f909e.zip
Make this compile after poll(2) change.
hin@ has the last word about it, tho.
-rw-r--r--kerberosIV/src/kadmin/admin_server.c7
-rw-r--r--kerberosIV/src/kadmin/kadm_locl.h1
2 files changed, 4 insertions, 4 deletions
diff --git a/kerberosIV/src/kadmin/admin_server.c b/kerberosIV/src/kadmin/admin_server.c
index 904c5849c68..c3aeef4f442 100644
--- a/kerberosIV/src/kadmin/admin_server.c
+++ b/kerberosIV/src/kadmin/admin_server.c
@@ -266,7 +266,6 @@ kadm_listen(void)
int admin_fd;
int peer_fd;
struct pollfd pfd[1];
- int nfds;
struct sockaddr_in peer;
int addrlen;
int pid;
@@ -305,14 +304,14 @@ kadm_listen(void)
kill_children();
return(0);
}
- if ((found = poll(pfd, 1, 0) == 0)
+ if ((found = poll(pfd, 1, -1)) == 0)
continue; /* no things read */
if (found < 0) {
if (errno != EINTR)
krb_log("select: %s",error_message(errno));
continue;
- }
- if (FD_ISSET(admin_fd, &readfds)) {
+ }
+ if (pfd[0].revents & POLLIN) {
/* accept the conn */
addrlen = sizeof(peer);
if ((peer_fd = accept(admin_fd, (struct sockaddr *)&peer,
diff --git a/kerberosIV/src/kadmin/kadm_locl.h b/kerberosIV/src/kadmin/kadm_locl.h
index ef163372539..e9cdb641558 100644
--- a/kerberosIV/src/kadmin/kadm_locl.h
+++ b/kerberosIV/src/kadmin/kadm_locl.h
@@ -97,6 +97,7 @@
#include <syslog.h>
#endif
+#include <poll.h>
#include <err.h>
#ifdef SOCKS