aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--net/ipv6/ip6_flowlabel.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/net/ipv6/ip6_flowlabel.c b/net/ipv6/ip6_flowlabel.c
index 7712578bdc66..593a67e8d3f6 100644
--- a/net/ipv6/ip6_flowlabel.c
+++ b/net/ipv6/ip6_flowlabel.c
@@ -377,8 +377,8 @@ fl_create(struct net *net, struct in6_flowlabel_req *freq, char __user *optval,
377 goto done; 377 goto done;
378 fl->share = freq->flr_share; 378 fl->share = freq->flr_share;
379 addr_type = ipv6_addr_type(&freq->flr_dst); 379 addr_type = ipv6_addr_type(&freq->flr_dst);
380 if ((addr_type&IPV6_ADDR_MAPPED) 380 if ((addr_type & IPV6_ADDR_MAPPED) ||
381 || addr_type == IPV6_ADDR_ANY) { 381 addr_type == IPV6_ADDR_ANY) {
382 err = -EINVAL; 382 err = -EINVAL;
383 goto done; 383 goto done;
384 } 384 }
@@ -421,8 +421,8 @@ static int mem_check(struct sock *sk)
421 421
422 if (room <= 0 || 422 if (room <= 0 ||
423 ((count >= FL_MAX_PER_SOCK || 423 ((count >= FL_MAX_PER_SOCK ||
424 (count > 0 && room < FL_MAX_SIZE/2) || room < FL_MAX_SIZE/4) 424 (count > 0 && room < FL_MAX_SIZE/2) || room < FL_MAX_SIZE/4) &&
425 && !capable(CAP_NET_ADMIN))) 425 !capable(CAP_NET_ADMIN)))
426 return -ENOBUFS; 426 return -ENOBUFS;
427 427
428 return 0; 428 return 0;