summaryrefslogtreecommitdiff
path: root/src/script.c
diff options
context:
space:
mode:
authorSteven Barth <steven@midlink.org>2015-04-14 08:24:44 +0200
committerSteven Barth <steven@midlink.org>2015-04-14 08:36:37 +0200
commit7c604492735809a6571623645a0b2d1f37e12d40 (patch)
tree98bf1c60f51262036a3cb8c4e9e215a40bbc3ac6 /src/script.c
parent19c64c524614ea7fdbcedcc50d6980f096ccadb9 (diff)
downloadodhcp6c-7c604492735809a6571623645a0b2d1f37e12d40.tar.gz
scan-code fixes
Diffstat (limited to 'src/script.c')
-rw-r--r--src/script.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/script.c b/src/script.c
index 30441b9..db227d9 100644
--- a/src/script.c
+++ b/src/script.c
@@ -247,7 +247,6 @@ static void s46_to_env(enum odhcp6c_state state, const uint8_t *data, size_t len
uint16_t otype, olen;
dhcpv6_for_each_option(data, &data[len], otype, olen, odata) {
struct dhcpv6_s46_rule *rule = (struct dhcpv6_s46_rule*)odata;
- struct dhcpv6_s46_dmr *dmr = (struct dhcpv6_s46_dmr*)odata;
struct dhcpv6_s46_v4v6bind *bind = (struct dhcpv6_s46_v4v6bind*)odata;
if (state != STATE_S46_LW && otype == DHCPV6_OPT_S46_RULE &&
@@ -283,7 +282,7 @@ static void s46_to_env(enum odhcp6c_state state, const uint8_t *data, size_t len
fprintf(fp, "br=%s,", buf6);
} else if (state == STATE_S46_MAPT && otype == DHCPV6_OPT_S46_DMR &&
olen >= sizeof(struct dhcpv6_s46_dmr)) {
- dmr = (struct dhcpv6_s46_dmr*)odata;
+ struct dhcpv6_s46_dmr *dmr = (struct dhcpv6_s46_dmr*)odata;
memset(&in6, 0, sizeof(in6));
size_t prefix6len = dmr->dmr_prefix6_len;
prefix6len = (prefix6len % 8 == 0) ? prefix6len / 8 : prefix6len / 8 + 1;