hc
2024-05-11 04dd17822334871b23ea2862f7798fb0e0007777
kernel/net/ipv4/metrics.c
....@@ -1,5 +1,6 @@
11 // SPDX-License-Identifier: GPL-2.0-only
22 #include <linux/netlink.h>
3
+#include <linux/nospec.h>
34 #include <linux/rtnetlink.h>
45 #include <linux/types.h>
56 #include <net/ip.h>
....@@ -28,6 +29,7 @@
2829 return -EINVAL;
2930 }
3031
32
+ type = array_index_nospec(type, RTAX_MAX + 1);
3133 if (type == RTAX_CC_ALGO) {
3234 char tmp[TCP_CA_NAME_MAX];
3335