summaryrefslogtreecommitdiffstats
path: root/net/sctp
diff options
context:
space:
mode:
Diffstat (limited to 'net/sctp')
-rw-r--r--net/sctp/input.c3
-rw-r--r--net/sctp/ipv6.c3
2 files changed, 2 insertions, 4 deletions
diff --git a/net/sctp/input.c b/net/sctp/input.c
index 042ec6c9ae24..2a192a7c5d81 100644
--- a/net/sctp/input.c
+++ b/net/sctp/input.c
@@ -389,9 +389,6 @@ void sctp_icmp_frag_needed(struct sock *sk, struct sctp_association *asoc,
if (!t || (t->pathmtu <= pmtu))
return;
- if (!ip6_sk_accept_pmtu(sk))
- return;
-
if (sock_owned_by_user(sk)) {
asoc->pmtu_pending = 1;
t->pmtu_pending = 1;
diff --git a/net/sctp/ipv6.c b/net/sctp/ipv6.c
index 317e13eb2c56..14191ab4165f 100644
--- a/net/sctp/ipv6.c
+++ b/net/sctp/ipv6.c
@@ -172,7 +172,8 @@ static void sctp_v6_err(struct sk_buff *skb, struct inet6_skb_parm *opt,
switch (type) {
case ICMPV6_PKT_TOOBIG:
- sctp_icmp_frag_needed(sk, asoc, transport, ntohl(info));
+ if (ip6_sk_accept_pmtu(sk))
+ sctp_icmp_frag_needed(sk, asoc, transport, ntohl(info));
goto out_unlock;
case ICMPV6_PARAMPROB:
if (ICMPV6_UNK_NEXTHDR == code) {
OpenPOWER on IntegriCloud