]> git.ipfire.org Git - thirdparty/ipset.git/commitdiff
treewide: rename nla_strlcpy to nla_strscpy.
authorFrancis Laniel <laniel_francis@privacyrequired.com>
Sun, 20 Dec 2020 12:31:40 +0000 (13:31 +0100)
committerJozsef Kadlecsik <kadlec@netfilter.org>
Sun, 20 Dec 2020 12:40:52 +0000 (13:40 +0100)
Calls to nla_strlcpy are now replaced by calls to nla_strscpy which is the new
name of this function.

Signed-off-by: Francis Laniel <laniel_francis@privacyrequired.com>
Reviewed-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
kernel/net/netfilter/ipset/ip_set_hash_netiface.c

index d17e6148ead9dcf34d4523cd3e41f008c49c82a0..58332eadc9d82e3a55d6db278780b9c5413a54fd 100644 (file)
@@ -227,7 +227,7 @@ hash_netiface4_uadt(struct ip_set *set, struct nlattr *tb[],
                if (e.cidr > HOST_MASK)
                        return -IPSET_ERR_INVALID_CIDR;
        }
-       nla_strlcpy(e.iface, tb[IPSET_ATTR_IFACE], IFNAMSIZ);
+       nla_strscpy(e.iface, tb[IPSET_ATTR_IFACE], IFNAMSIZ);
 
        if (tb[IPSET_ATTR_CADT_FLAGS]) {
                u32 cadt_flags = ip_set_get_h32(tb[IPSET_ATTR_CADT_FLAGS]);
@@ -444,7 +444,7 @@ hash_netiface6_uadt(struct ip_set *set, struct nlattr *tb[],
 
        ip6_netmask(&e.ip, e.cidr);
 
-       nla_strlcpy(e.iface, tb[IPSET_ATTR_IFACE], IFNAMSIZ);
+       nla_strscpy(e.iface, tb[IPSET_ATTR_IFACE], IFNAMSIZ);
 
        if (tb[IPSET_ATTR_CADT_FLAGS]) {
                u32 cadt_flags = ip_set_get_h32(tb[IPSET_ATTR_CADT_FLAGS]);