#define endfor_nexthops(fi) }
-static const struct
+static const struct
{
int error;
u8 scope;
-} fib_props[RTA_MAX + 1] = {
- {
+} fib_props[RTN_MAX + 1] = {
+ {
.error = 0,
.scope = RT_SCOPE_NOWHERE,
}, /* RTN_UNSPEC */
rtnh = cfg->fc_mp;
remaining = cfg->fc_mp_len;
-
+
for_nexthops(fi) {
int attrlen;
Normally it looks as following.
{universe prefix} -> (gw, oif) [scope link]
- |
+ |
|-> {link prefix} -> (gw, oif) [scope local]
- |
+ |
|-> {local prefix} (terminal node)
*/
err = -EINVAL;
failure:
- if (fi) {
+ if (fi) {
fi->fib_dead = 1;
free_fib_info(fi);
}
{
int ret = 0;
int scope = RT_SCOPE_NOWHERE;
-
+
if (force)
scope = -1;