socsvn commit: r287737 - soc2015/roam/ng_ayiya

roam at FreeBSD.org roam at FreeBSD.org
Mon Jun 29 19:03:24 UTC 2015


Author: roam
Date: Mon Jun 29 19:03:22 2015
New Revision: 287737
URL: http://svnweb.FreeBSD.org/socsvn/?view=rev&rev=287737

Log:
  Perform the link-local check in a sensible way.
  
  There's a macro for that!
  
  Pointed out by:	bz (mentor)
  Didn't read the next page of in6.h:	roam (myself)

Modified:
  soc2015/roam/ng_ayiya/ng_ayiya.c

Modified: soc2015/roam/ng_ayiya/ng_ayiya.c
==============================================================================
--- soc2015/roam/ng_ayiya/ng_ayiya.c	Mon Jun 29 19:03:19 2015	(r287736)
+++ soc2015/roam/ng_ayiya/ng_ayiya.c	Mon Jun 29 19:03:22 2015	(r287737)
@@ -456,7 +456,7 @@
 			 * client has set the appropriate tunnel endpoint IPv6
 			 * address on the interface by now.
 			 */
-			if ((htons(a->sin6_addr.s6_addr16[0]) & 0xFFC0) == 0xFE80)
+			if (IN6_IS_ADDR_LINKLOCAL(&a->sin6_addr))
 				continue;
 
 			const priv_p priv = NG_NODE_PRIVATE(node);


More information about the svn-soc-all mailing list