MFC 206454:

When embedding the scope ID in MLDv1 output, check if the scope of the address
  being embedded is in fact link-local, before attempting to embed it.

  Note that this operation is a side-effect of trying to avoid recursion on
  the IN6 scope lock.

PR:		144560
Submitted by:	Petr Lampa
This commit is contained in:
Bruce M Simpson 2010-04-27 13:27:51 +00:00
parent ea5e5dda7b
commit 300cdd3c94

View file

@ -195,8 +195,10 @@ static int sysctl_mld_ifinfo(SYSCTL_HANDLER_ARGS);
static struct mtx mld_mtx;
MALLOC_DEFINE(M_MLD, "mld", "mld state");
#define MLD_EMBEDSCOPE(pin6, zoneid) \
(pin6)->s6_addr16[1] = htons((zoneid) & 0xFFFF)
#define MLD_EMBEDSCOPE(pin6, zoneid) \
if (IN6_IS_SCOPE_LINKLOCAL(pin6) || \
IN6_IS_ADDR_MC_INTFACELOCAL(pin6)) \
(pin6)->s6_addr16[1] = htons((zoneid) & 0xFFFF) \
/*
* VIMAGE-wide globals.