diff options
| author | Peter Wemm <peter@FreeBSD.org> | 1995-07-18 05:07:02 +0000 |
|---|---|---|
| committer | Peter Wemm <peter@FreeBSD.org> | 1995-07-18 05:07:02 +0000 |
| commit | 6367cd09b8e9bb8e55a45141b1f72c61645bb344 (patch) | |
| tree | 634909eabc0088402970b635ef9b7031890c18e8 /usr.bin/w | |
| parent | 7908b94389482f8cea55e2072f288ac356f50947 (diff) | |
Notes
Diffstat (limited to 'usr.bin/w')
| -rw-r--r-- | usr.bin/w/w.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/usr.bin/w/w.c b/usr.bin/w/w.c index 685057d81e7f9..6e006ad51bc66 100644 --- a/usr.bin/w/w.c +++ b/usr.bin/w/w.c @@ -77,6 +77,9 @@ static char sccsid[] = "@(#)w.c 8.4 (Berkeley) 4/16/94"; #include <utmp.h> #include <vis.h> +#include <arpa/nameser.h> +#include <resolv.h> + #include "extern.h" struct timeval boottime; @@ -169,6 +172,11 @@ main(argc, argv) argc -= optind; argv += optind; + if (!(_res.options & RES_INIT)) + res_init(); + _res.retrans = 2; /* resolver timeout to 2 seconds per try */ + _res.retry = 1; /* only try once.. */ + if ((kd = kvm_openfiles(nlistf, memf, NULL, O_RDONLY, errbuf)) == NULL) errx(1, "%s", errbuf); |
