Skip to content

Commit

Permalink
ip6_getpktaddrs() should return -1 if the stored addresses are invalid.
Browse files Browse the repository at this point in the history
  • Loading branch information
jinmei committed Apr 4, 2003
1 parent 354c95c commit dd8d3c2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion kame/sys/netinet6/ip6_input.c
@@ -1,4 +1,4 @@
/* $KAME: ip6_input.c,v 1.308 2003/04/02 10:06:48 itojun Exp $ */
/* $KAME: ip6_input.c,v 1.309 2003/04/04 09:28:37 jinmei Exp $ */

/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
Expand Down Expand Up @@ -1336,6 +1336,7 @@ ip6_getpktaddrs(m, src, dst)
if (((struct ip6aux *)(mtag + 1))->ip6a_src.sin6_family != AF_INET6 ||
((struct ip6aux *)(mtag + 1))->ip6a_dst.sin6_family != AF_INET6) {
printf("ip6_getpktaddrs: src or dst are invalid\n");
return (-1);
}

if (src)
Expand Down

0 comments on commit dd8d3c2

Please sign in to comment.