Message ID | 20220325150415.769462574@linuxfoundation.org |
---|---|
State | New |
Headers | show |
Series | None | expand |
--- a/net/ipv6/ip6_output.c +++ b/net/ipv6/ip6_output.c @@ -1329,8 +1329,8 @@ static int __ip6_append_data(struct sock sizeof(struct frag_hdr) : 0) + rt->rt6i_nfheader_len; - if (mtu < fragheaderlen || - ((mtu - fragheaderlen) & ~7) + fragheaderlen < sizeof(struct frag_hdr)) + if (mtu <= fragheaderlen || + ((mtu - fragheaderlen) & ~7) + fragheaderlen <= sizeof(struct frag_hdr)) goto emsgsize; maxfraglen = ((mtu - fragheaderlen) & ~7) + fragheaderlen -