summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorume <ume@FreeBSD.org>2005-05-13 16:43:28 +0000
committerume <ume@FreeBSD.org>2005-05-13 16:43:28 +0000
commit7ef908f6aafd522979d4950ea468ff9d9c6e3c0a (patch)
tree055e2b0d0d4a15cd0d24a6401883a8681ce756b9
parente33ba033454acbec171e04edba1395842e412b5c (diff)
downloadFreeBSD-src-7ef908f6aafd522979d4950ea468ff9d9c6e3c0a.zip
FreeBSD-src-7ef908f6aafd522979d4950ea468ff9d9c6e3c0a.tar.gz
NI_WITHSCOPEID cleanup
Reviewed by: gad
-rw-r--r--usr.sbin/lpr/common_source/net.c4
-rw-r--r--usr.sbin/lpr/lpd/lpd.c6
2 files changed, 5 insertions, 5 deletions
diff --git a/usr.sbin/lpr/common_source/net.c b/usr.sbin/lpr/common_source/net.c
index 3ae3e90..2a1e0c8 100644
--- a/usr.sbin/lpr/common_source/net.c
+++ b/usr.sbin/lpr/common_source/net.c
@@ -230,13 +230,13 @@ checkremote(struct printer *pp)
for (lr = local_res; lr; lr = lr->ai_next) {
h1[0] = '\0';
if (getnameinfo(lr->ai_addr, lr->ai_addrlen, h1, sizeof(h1),
- NULL, 0, NI_NUMERICHOST | NI_WITHSCOPEID) != 0)
+ NULL, 0, NI_NUMERICHOST) != 0)
continue;
for (rr = remote_res; rr; rr = rr->ai_next) {
h2[0] = '\0';
if (getnameinfo(rr->ai_addr, rr->ai_addrlen,
h2, sizeof(h2), NULL, 0,
- NI_NUMERICHOST | NI_WITHSCOPEID) != 0)
+ NI_NUMERICHOST) != 0)
continue;
if (strcmp(h1, h2) == 0)
ncommonaddrs++;
diff --git a/usr.sbin/lpr/lpd/lpd.c b/usr.sbin/lpr/lpd/lpd.c
index e02839a..51a228b 100644
--- a/usr.sbin/lpr/lpd/lpd.c
+++ b/usr.sbin/lpr/lpd/lpd.c
@@ -675,7 +675,7 @@ chkhost(struct sockaddr *f, int ch_opts)
if (error) {
errsav = error;
error = getnameinfo(f, f->sa_len, hostbuf, sizeof(hostbuf),
- NULL, 0, NI_NUMERICHOST | NI_WITHSCOPEID);
+ NULL, 0, NI_NUMERICHOST);
if (error) {
asprintf(&syserr,
"can not determine hostname for remote host (%d,%d)",
@@ -701,7 +701,7 @@ chkhost(struct sockaddr *f, int ch_opts)
/* Need address in stringform for comparison (no DNS lookup here) */
error = getnameinfo(f, f->sa_len, hostbuf, sizeof(hostbuf), NULL, 0,
- NI_NUMERICHOST | NI_WITHSCOPEID);
+ NI_NUMERICHOST);
if (error) {
asprintf(&syserr, "Cannot print IP address (error %d)",
error);
@@ -743,7 +743,7 @@ chkhost(struct sockaddr *f, int ch_opts)
good = 0;
for (r = res; good == 0 && r; r = r->ai_next) {
error = getnameinfo(r->ai_addr, r->ai_addrlen, ip, sizeof(ip),
- NULL, 0, NI_NUMERICHOST | NI_WITHSCOPEID);
+ NULL, 0, NI_NUMERICHOST);
if (!error && !strcmp(from_ip, ip))
good = 1;
}
OpenPOWER on IntegriCloud