Use strlcpy instead of incorrectly using strncpy.
MFC after: 2 weeks
This commit is contained in:
parent
56373a5196
commit
2386a44f8b
@ -82,7 +82,7 @@ getether(ifname, eap)
|
||||
int nit;
|
||||
|
||||
bzero((char *) &ifrnit, sizeof(ifrnit));
|
||||
strncpy(&ifrnit.ifr_name[0], ifname, IFNAMSIZ);
|
||||
strlcpy(&ifrnit.ifr_name[0], ifname, IFNAMSIZ);
|
||||
|
||||
nit = open("/dev/nit", 0);
|
||||
if (nit < 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user