diff options
author | roberto <roberto@FreeBSD.org> | 2000-06-18 23:45:17 +0000 |
---|---|---|
committer | roberto <roberto@FreeBSD.org> | 2000-06-18 23:45:17 +0000 |
commit | 9c3dcc7bed8fd16b488c5e3c331dd4e6f6512d47 (patch) | |
tree | 1a9d62c5e6a5007b9231e3c4e1a137d7c03fd640 /usr.sbin/wicontrol | |
parent | 2628a3eeecdf7ff471eb9cbb186b05e72b47398d (diff) | |
download | FreeBSD-src-9c3dcc7bed8fd16b488c5e3c331dd4e6f6512d47.zip FreeBSD-src-9c3dcc7bed8fd16b488c5e3c331dd4e6f6512d47.tar.gz |
Bring the ancontrol buffer oflows fixes here too.
Submitted by: Aaron Campbell <aaron@openbsd.org>
Diffstat (limited to 'usr.sbin/wicontrol')
-rw-r--r-- | usr.sbin/wicontrol/wicontrol.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/wicontrol/wicontrol.c b/usr.sbin/wicontrol/wicontrol.c index aef613f..676668a 100644 --- a/usr.sbin/wicontrol/wicontrol.c +++ b/usr.sbin/wicontrol/wicontrol.c @@ -83,7 +83,7 @@ static void wi_getval(iface, wreq) bzero((char *)&ifr, sizeof(ifr)); - strcpy(ifr.ifr_name, iface); + strlcpy(ifr.ifr_name, iface, sizeof(ifr.ifr_name)); ifr.ifr_data = (caddr_t)wreq; s = socket(AF_INET, SOCK_DGRAM, 0); @@ -108,7 +108,7 @@ static void wi_setval(iface, wreq) bzero((char *)&ifr, sizeof(ifr)); - strcpy(ifr.ifr_name, iface); + strlcpy(ifr.ifr_name, iface, sizeof(ifr.ifr_name)); ifr.ifr_data = (caddr_t)wreq; s = socket(AF_INET, SOCK_DGRAM, 0); |