From: Hans Dedecker Date: Mon, 3 Sep 2018 11:46:28 +0000 (+0200) Subject: config: fix odhcpd_attrs array size X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=3e17fd926ff0f8feae97ff7c86dd5ce282315490;p=project%2Fodhcpd.git config: fix odhcpd_attrs array size Use ODHCPD_ATTR_MAX as array size of odhcpd_attrs Signed-off-by: Hans Dedecker --- diff --git a/src/config.c b/src/config.c index 118349a..6556eac 100644 --- a/src/config.c +++ b/src/config.c @@ -153,7 +153,7 @@ enum { ODHCPD_ATTR_MAX }; -static const struct blobmsg_policy odhcpd_attrs[LEASE_ATTR_MAX] = { +static const struct blobmsg_policy odhcpd_attrs[ODHCPD_ATTR_MAX] = { [ODHCPD_ATTR_LEGACY] = { .name = "legacy", .type = BLOBMSG_TYPE_BOOL }, [ODHCPD_ATTR_MAINDHCP] = { .name = "maindhcp", .type = BLOBMSG_TYPE_BOOL }, [ODHCPD_ATTR_LEASEFILE] = { .name = "leasefile", .type = BLOBMSG_TYPE_STRING },