diff options
Diffstat (limited to 'zebra/ioctl.c')
| -rw-r--r-- | zebra/ioctl.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/zebra/ioctl.c b/zebra/ioctl.c index 835f1f4934..4404bb4483 100644 --- a/zebra/ioctl.c +++ b/zebra/ioctl.c @@ -44,7 +44,7 @@ extern struct zebra_privs_t zserv_privs; /* clear and set interface name string */ void ifreq_set_name(struct ifreq *ifreq, struct interface *ifp) { - strncpy(ifreq->ifr_name, ifp->name, IFNAMSIZ); + strlcpy(ifreq->ifr_name, ifp->name, sizeof(ifreq->ifr_name)); } /* call ioctl system call */ |
