mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-11 01:40:19 +01:00
core/platform: replace strcpy by g_strlcpy
Signed-off-by: Thomas Haller <thaller@redhat.com>
This commit is contained in:
parent
c9e241e2f9
commit
fa81901ed8
1 changed files with 1 additions and 1 deletions
|
|
@ -692,7 +692,7 @@ link_init (NMPlatform *platform, NMPlatformLink *info, struct rtnl_link *rtnllin
|
|||
g_assert (rtnllink);
|
||||
|
||||
info->ifindex = rtnl_link_get_ifindex (rtnllink);
|
||||
strcpy (info->name, rtnl_link_get_name (rtnllink));
|
||||
g_strlcpy (info->name, rtnl_link_get_name (rtnllink), sizeof (info->name));
|
||||
info->type = link_extract_type (platform, rtnllink, &info->type_name);
|
||||
info->up = !!(rtnl_link_get_flags (rtnllink) & IFF_UP);
|
||||
info->connected = !!(rtnl_link_get_flags (rtnllink) & IFF_LOWER_UP);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue