summaryrefslogtreecommitdiff
path: root/nest
diff options
context:
space:
mode:
Diffstat (limited to 'nest')
-rw-r--r--nest/config.Y6
-rw-r--r--nest/rt-table.c3
2 files changed, 4 insertions, 5 deletions
diff --git a/nest/config.Y b/nest/config.Y
index e5a6e0bb..612e4d40 100644
--- a/nest/config.Y
+++ b/nest/config.Y
@@ -98,10 +98,8 @@ idval:
| SYM {
if ($1->class == (SYM_CONSTANT | T_INT) || $1->class == (SYM_CONSTANT | T_QUAD))
$$ = SYM_VAL($1).i;
-#ifndef IPV6
- else if ($1->class == (SYM_CONSTANT | T_IP))
- $$ = ipa_to_u32(SYM_VAL($1).px.ip);
-#endif
+ else if (($1->class == (SYM_CONSTANT | T_IP)) && ipa_is_ip4(SYM_VAL($1).ip))
+ $$ = ipa_to_u32(SYM_VAL($1).ip);
else
cf_error("Number of IPv4 address constant expected");
}
diff --git a/nest/rt-table.c b/nest/rt-table.c
index 05073ce0..6ac659a8 100644
--- a/nest/rt-table.c
+++ b/nest/rt-table.c
@@ -2293,13 +2293,14 @@ rt_update_hostentry(rtable *tab, struct hostentry *he)
he->igp_metric = rt_get_igp_metric(e);
}
- /* XXXX */
done:
/* Add a prefix range to the trie */
+ /* XXXX
if (ipa_is_ip4(he->addr))
trie_add_prefix(tab->hostcache->trie, he->addr, IP4_MAX_PREFIX_LENGTH, pxlen, IP4_MAX_PREFIX_LENGTH);
else
trie_add_prefix(tab->hostcache->trie, he->addr, IP6_MAX_PREFIX_LENGTH, pxlen, IP6_MAX_PREFIX_LENGTH);
+ */
rta_free(old_src);
return old_src != he->src;