aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenis Vlasenko <vda.linux@googlemail.com>2009-04-26 01:43:36 +0000
committerDenis Vlasenko <vda.linux@googlemail.com>2009-04-26 01:43:36 +0000
commit80e57eb7d525803bb776e8294483141756b2b2ef (patch)
tree2f6edc0f54906953fb6a95c5a4161e2115627431
parentf4e4563fe7030d2ed574fef837478128b40516c9 (diff)
downloadbusybox-w32-80e57eb7d525803bb776e8294483141756b2b2ef.tar.gz
busybox-w32-80e57eb7d525803bb776e8294483141756b2b2ef.tar.bz2
busybox-w32-80e57eb7d525803bb776e8294483141756b2b2ef.zip
ifplugd: tiny shrink
-rw-r--r--networking/ifplugd.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/networking/ifplugd.c b/networking/ifplugd.c
index 3d7f2a98a..3315e9a4d 100644
--- a/networking/ifplugd.c
+++ b/networking/ifplugd.c
@@ -222,7 +222,7 @@ static int network_ioctl(int request, void* data)
222static void set_ifreq_to_ifname(struct ifreq *ifreq) 222static void set_ifreq_to_ifname(struct ifreq *ifreq)
223{ 223{
224 memset(ifreq, 0, sizeof(struct ifreq)); 224 memset(ifreq, 0, sizeof(struct ifreq));
225 strncpy(ifreq->ifr_name, G.iface, IFNAMSIZ); 225 strncpy_IFNAMSIZ(ifreq->ifr_name, G.iface);
226} 226}
227 227
228static const char *strstatus(int status) 228static const char *strstatus(int status)
@@ -389,7 +389,7 @@ static smallint detect_link_wlan(void)
389 uint8_t mac[ETH_ALEN]; 389 uint8_t mac[ETH_ALEN];
390 390
391 memset(&iwrequest, 0, sizeof(struct iwreq)); 391 memset(&iwrequest, 0, sizeof(struct iwreq));
392 strncpy(iwrequest.ifr_ifrn.ifrn_name, G.iface, IFNAMSIZ); 392 strncpy_IFNAMSIZ(iwrequest.ifr_ifrn.ifrn_name, G.iface);
393 393
394 if (network_ioctl(SIOCGIWAP, &iwrequest) < 0) { 394 if (network_ioctl(SIOCGIWAP, &iwrequest) < 0) {
395 bb_perror_msg("SIOCGIWAP failed"); 395 bb_perror_msg("SIOCGIWAP failed");