mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-04 16:50:17 +01:00
ppp: avoid strncpy() in ppp plugin nm_phasechange()
strncpy() is deemed insecure, and it raises at least an eyebrow. While it's save in this case, just avoid it.
This commit is contained in:
parent
30a469e0bb
commit
4d11eba8c5
1 changed files with 1 additions and 1 deletions
|
|
@ -147,7 +147,7 @@ nm_phasechange (void *data, int arg)
|
|||
if ( if_indextoname (index, new_name)
|
||||
&& !nm_streq0 (ifname, new_name)) {
|
||||
g_message ("nm-ppp-plugin: interface name changed from '%s' to '%s'", ifname, new_name);
|
||||
strncpy (ifname, new_name, IF_NAMESIZE);
|
||||
g_strlcpy (ifname, new_name, IF_NAMESIZE);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue