Skip to content
Browse files

coped with the difference of the return value of nd6_storeaddr() betw…

…een KAME and FreeBSD-5.3
  • Loading branch information...
1 parent 2711faa commit 1ba82a7aaaaef34aa97bc4199b3258d6d028083b suz committed Nov 12, 2004
View
9 freebsd5/sys/net/if_arcsubr.c
@@ -169,9 +169,12 @@ arc_output(ifp, m, dst, rt0)
#endif
#ifdef INET6
case AF_INET6:
- error = nd6_storelladdr(ifp, rt0, m, dst, (u_char *)&adst);
- if (error)
- return (error);
+ /*
+ * XXX: nd6_storelladdr()'s return value has different
+ * meaning between FreeBSD and KAME.
+ */
+ if (!nd6_storelladdr(ifp, rt0, m, dst, (u_char *)&adst))
+ return (EINVAL); /* XXX */
atype = ARCTYPE_INET6;
break;
#endif
View
9 freebsd5/sys/net/if_ethersubr.c
@@ -192,9 +192,12 @@ ether_output(struct ifnet *ifp, struct mbuf *m,
#endif
#ifdef INET6
case AF_INET6:
- error = nd6_storelladdr(ifp, rt0, m, dst, (u_char *)edst);
- if (error)
- return error;
+ /*
+ * XXX: nd6_storelladdr()'s return value has different
+ * meaning between FreeBSD and KAME.
+ */
+ if (!nd6_storelladdr(ifp, rt0, m, dst, (u_char *)edst))
+ return (EINVAL); /* XXX */
type = htons(ETHERTYPE_IPV6);
break;
#endif
View
9 freebsd5/sys/net/if_fddisubr.c
@@ -192,9 +192,12 @@ fddi_output(ifp, m, dst, rt0)
#endif /* INET */
#ifdef INET6
case AF_INET6:
- error = nd6_storelladdr(ifp, rt0, m, dst, (u_char *)edst);
- if (error)
- return (error); /* Something bad happened */
+ /*
+ * XXX: nd6_storelladdr()'s return value has different
+ * meaning between FreeBSD and KAME.
+ */
+ if (!nd6_storelladdr(ifp, rt0, m, dst, (u_char *)edst))
+ return (EINVAL); /* XXX */
type = htons(ETHERTYPE_IPV6);
break;
#endif /* INET6 */
View
11 freebsd5/sys/net/if_fwsubr.c
@@ -169,10 +169,13 @@ firewire_output(struct ifnet *ifp, struct mbuf *m, struct sockaddr *dst,
#ifdef INET6
case AF_INET6:
if (unicast) {
- error = nd6_storelladdr(&fc->fc_if, rt, m, dst,
- (u_char *) destfw);
- if (error)
- return (error);
+ /*
+ * XXX: nd6_storelladdr()'s return value has different
+ * meaning between FreeBSD and KAME.
+ */
+ if (!nd6_storelladdr(&fc->fc_if, rt, m, dst,
+ (u_char *) destfw))
+ return (EINVAL); /* XXX */
}
type = ETHERTYPE_IPV6;
break;
View
9 freebsd5/sys/net/if_iso88025subr.c
@@ -328,9 +328,12 @@ iso88025_output(ifp, m, dst, rt0)
#endif /* INET */
#ifdef INET6
case AF_INET6:
- error = nd6_storelladdr(ifp, rt0, m, dst, (u_char *)edst);
- if (error)
- return (error);
+ /*
+ * XXX: nd6_storelladdr()'s return value has different
+ * meaning between FreeBSD and KAME.
+ */
+ if (!nd6_storelladdr(ifp, rt0, m, dst, (u_char *)edst))
+ return (EINVAL); /* XXX */
snap_type = ETHERTYPE_IPV6;
break;
#endif /* INET6 */

0 comments on commit 1ba82a7

Please sign in to comment.
Something went wrong with that request. Please try again.