From: Roy Marples Date: Wed, 19 Jun 2019 10:41:06 +0000 (+0000) Subject: Remove now unused variables. X-Git-Tag: v8.0.0~27^2~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d604214e9310001c008ad64d915a9def3107e8cd;p=thirdparty%2Fdhcpcd.git Remove now unused variables. --- diff --git a/src/dhcp-common.c b/src/dhcp-common.c index 6d66ebef..45a26b2a 100644 --- a/src/dhcp-common.c +++ b/src/dhcp-common.c @@ -627,7 +627,7 @@ print_option(FILE *fp, const char *prefix, const struct dhcp_opt *opt, uint32_t u32; int32_t s32; struct in_addr addr; - ssize_t bytes = 0, sl; + ssize_t sl; size_t l; /* Ensure a valid length */ @@ -679,7 +679,6 @@ print_option(FILE *fp, const char *prefix, const struct dhcp_opt *opt, if (opt->type & OT_BITFLAG) { /* bitflags are a string, MSB first, such as ABCDEFGH * where A is 10000000, B is 01000000, etc. */ - bytes = 0; for (l = 0, sl = sizeof(opt->bitflags) - 1; l < sizeof(opt->bitflags); l++, sl--) diff --git a/src/dhcp.c b/src/dhcp.c index 7b854136..781f2a0e 100644 --- a/src/dhcp.c +++ b/src/dhcp.c @@ -1290,12 +1290,11 @@ dhcp_env(FILE *fenv, const char *prefix, const struct interface *ifp, struct in_addr net; struct in_addr brd; struct dhcp_opt *opt, *vo; - size_t e, i, pl; + size_t i, pl; char safe[(BOOTP_FILE_LEN * 4) + 1]; uint8_t overl = 0; uint32_t en; - e = 0; ifo = ifp->options; if (get_option_uint8(ifp->ctx, &overl, bootp, bootp_len, DHO_OPTSOVERLOADED) == -1) diff --git a/src/dhcp6.c b/src/dhcp6.c index 6ebb591a..85ceef98 100644 --- a/src/dhcp6.c +++ b/src/dhcp6.c @@ -3959,7 +3959,7 @@ dhcp6_env(FILE *fp, const char *prefix, const struct interface *ifp, struct dhcp_opt *opt, *vo; const uint8_t *p; struct dhcp6_option o; - size_t i, n; + size_t i; char *pfx; uint32_t en; const struct dhcpcd_ctx *ctx; @@ -3968,7 +3968,6 @@ dhcp6_env(FILE *fp, const char *prefix, const struct interface *ifp, const struct ipv6_addr *ap; #endif - n = 0; if (m == NULL) goto delegated;