We were memsetting zebra_pbr_rule struct after
we had already put some information in it. Also updated
the init of the struct to use braces instead of a
memset.
Signed-off-by: Stephen Worley <sworley@cumulusnetworks.com>
struct rtattr *tb[FRA_MAX + 1];
int len;
char *ifname;
- struct zebra_pbr_rule rule;
+ struct zebra_pbr_rule rule = {};
char buf1[PREFIX_STRLEN];
char buf2[PREFIX_STRLEN];
if (!rule.ifp)
return 0;
- memset(&rule, 0, sizeof(rule));
if (tb[FRA_PRIORITY])
rule.rule.priority = *(uint32_t *)RTA_DATA(tb[FRA_PRIORITY]);