summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2000-01-04 10:39:22 +0000
committerJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2000-01-04 10:39:22 +0000
commitf6b416e15426d15d1517ed6adb60621fedb76f48 (patch)
tree764f19af6e70cb95c89ce243878accb18915e800
parent5947f317ca3586d3e3ee32a3abd14215e53aef56 (diff)
if we call in6_setpeeraddr, don't visit code for ipv4.
(the case seems to be never bisited)
-rw-r--r--sys/netinet/in_pcb.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/netinet/in_pcb.c b/sys/netinet/in_pcb.c
index 2d0e5d7ddd8..d6e89ff201c 100644
--- a/sys/netinet/in_pcb.c
+++ b/sys/netinet/in_pcb.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: in_pcb.c,v 1.39 1999/12/19 01:57:07 angelos Exp $ */
+/* $OpenBSD: in_pcb.c,v 1.40 2000/01/04 10:39:21 itojun Exp $ */
/* $NetBSD: in_pcb.c,v 1.25 1996/02/13 23:41:53 christos Exp $ */
/*
@@ -592,8 +592,10 @@ in_setpeeraddr(inp, nam)
register struct sockaddr_in *sin;
#ifdef INET6
- if (sotopf(inp->inp_socket) == PF_INET6)
+ if (sotopf(inp->inp_socket) == PF_INET6) {
in6_setpeeraddr(inp, nam);
+ return;
+ }
#endif /* INET6 */
nam->m_len = sizeof (*sin);