mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-28 11:57:28 +00:00
Fix a bug where Multicast packets sent from a
udp endpoint may end up echoing back to the sender even with OUT joining the multi-cast group. Reviewed by: gnn, bms, bz? Obtained from: deischen (with help from)
This commit is contained in:
parent
fbfbce8ae9
commit
a38b1c8c5e
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=217592
@ -479,11 +479,13 @@ udp_input(struct mbuf *m, int off)
|
||||
* and source-specific multicast. [RFC3678]
|
||||
*/
|
||||
imo = inp->inp_moptions;
|
||||
if (IN_MULTICAST(ntohl(ip->ip_dst.s_addr)) &&
|
||||
imo != NULL) {
|
||||
if (IN_MULTICAST(ntohl(ip->ip_dst.s_addr))) {
|
||||
struct sockaddr_in group;
|
||||
int blocked;
|
||||
|
||||
if(imo == NULL) {
|
||||
INP_RUNLOCK(inp);
|
||||
continue;
|
||||
}
|
||||
bzero(&group, sizeof(struct sockaddr_in));
|
||||
group.sin_len = sizeof(struct sockaddr_in);
|
||||
group.sin_family = AF_INET;
|
||||
|
Loading…
Reference in New Issue
Block a user