Some recent improvement in GCC triggers 2 new warnings, and they're
actual bugs (reading beyond end of prefix_ipv6 by accessing it as
prefix, which is larger.) Luckily it's only in sharpd.
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit
5c7a6fb36c0cf8113c19af7354782838988b263b)
p.family = AF_INET6;
} else {
type_import = true;
- p = *(const struct prefix *)inhop;
+ prefix_copy(&p, inhop);
}
sharp_nh_tracker_get(&p);
}
else {
type_import = true;
- p = *(const struct prefix *)inhop;
+ prefix_copy(&p, inhop);
}
sharp_nh_tracker_get(&p);