summaryrefslogtreecommitdiffstats
path: root/dhcpcd.c
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2015-05-01 16:06:39 +0000
committerRoy Marples <roy@marples.name>2015-05-01 16:06:39 +0000
commit225dcdbdebb4baecf44b24df2d45644e0f32a3f4 (patch)
tree3c5bca84b2a2eced8b08b0aa399f15792024cc64 /dhcpcd.c
parent2f53bfd408f7c26fbe73febf466ec3bfe8bbdf61 (diff)
downloaddhcpcd-225dcdbdebb4baecf44b24df2d45644e0f32a3f4.tar.xz
Fix some compiler warnings.
Diffstat (limited to 'dhcpcd.c')
-rw-r--r--dhcpcd.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/dhcpcd.c b/dhcpcd.c
index 18c19e99..2ffdac1d 100644
--- a/dhcpcd.c
+++ b/dhcpcd.c
@@ -658,10 +658,12 @@ dhcpcd_handlecarrier(struct dhcpcd_ctx *ctx, int carrier, unsigned int flags,
dhcpcd_handleinterface(ctx, 0, ifp->name);
#endif
if (ifp->wireless) {
- size_t olen;
uint8_t ossid[IF_SSIDSIZE];
+#ifdef NOCARRIER_PRESERVE_IP
+ size_t olen;
olen = ifp->ssid_len;
+#endif
memcpy(ossid, ifp->ssid, ifp->ssid_len);
if_getssid(ifp);
#ifdef NOCARRIER_PRESERVE_IP