mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-04 08:09:08 +00:00
MFC r318255:
Add missing braces around MCAST_EXCLUDE check when KTR support is compiled into the kernel This ensures that .iss_asm (the number of ASM listeners) isn't incorrectly decremented for MLD-layer source datagrams when inspecting im*s_st[1] (the second state in the structure). PR: 217509 [1]
This commit is contained in:
parent
21a39509f4
commit
888aa3fbe0
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/stable/10/; revision=321134
@ -1014,9 +1014,10 @@ inm_merge(struct in_multi *inm, /*const*/ struct in_mfilter *imf)
|
||||
/* Decrement ASM listener count on transition out of ASM mode. */
|
||||
if (imf->imf_st[0] == MCAST_EXCLUDE && nsrc0 == 0) {
|
||||
if ((imf->imf_st[1] != MCAST_EXCLUDE) ||
|
||||
(imf->imf_st[1] == MCAST_EXCLUDE && nsrc1 > 0))
|
||||
(imf->imf_st[1] == MCAST_EXCLUDE && nsrc1 > 0)) {
|
||||
CTR1(KTR_IGMPV3, "%s: --asm on inm at t1", __func__);
|
||||
--inm->inm_st[1].iss_asm;
|
||||
}
|
||||
}
|
||||
|
||||
/* Increment ASM listener count on transition to ASM mode. */
|
||||
|
@ -1000,9 +1000,10 @@ in6m_merge(struct in6_multi *inm, /*const*/ struct in6_mfilter *imf)
|
||||
/* Decrement ASM listener count on transition out of ASM mode. */
|
||||
if (imf->im6f_st[0] == MCAST_EXCLUDE && nsrc0 == 0) {
|
||||
if ((imf->im6f_st[1] != MCAST_EXCLUDE) ||
|
||||
(imf->im6f_st[1] == MCAST_EXCLUDE && nsrc1 > 0))
|
||||
(imf->im6f_st[1] == MCAST_EXCLUDE && nsrc1 > 0)) {
|
||||
CTR1(KTR_MLD, "%s: --asm on inm at t1", __func__);
|
||||
--inm->in6m_st[1].iss_asm;
|
||||
}
|
||||
}
|
||||
|
||||
/* Increment ASM listener count on transition to ASM mode. */
|
||||
|
Loading…
Reference in New Issue
Block a user