diff options
author | Ondrej Zajicek <santiago@crfreenet.org> | 2009-10-12 20:44:58 +0200 |
---|---|---|
committer | Ondrej Zajicek <santiago@crfreenet.org> | 2009-10-12 20:44:58 +0200 |
commit | 52b9b2a1786140c38af03de570b0cc96c835c1d3 (patch) | |
tree | a19f18654f2ef3aed6d9d369258e9e8d693474f8 /proto/bgp | |
parent | ea89da381fc682155e7d08d6ad3d4ac8aa5fe115 (diff) |
Rename as_path_get_last/as_path_get_first to be consistent.
Diffstat (limited to 'proto/bgp')
-rw-r--r-- | proto/bgp/attrs.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/proto/bgp/attrs.c b/proto/bgp/attrs.c index 831ada57..d839ed09 100644 --- a/proto/bgp/attrs.c +++ b/proto/bgp/attrs.c @@ -996,7 +996,7 @@ bgp_get_neighbor(rte *r) eattr *e = ea_find(r->attrs->eattrs, EA_CODE(EAP_BGP, BA_AS_PATH)); u32 as; - if (e && as_path_get_last(e->u.ptr, &as)) + if (e && as_path_get_first(e->u.ptr, &as)) return as; else return ((struct bgp_proto *) r->attrs->proto)->remote_as; @@ -1470,7 +1470,7 @@ bgp_get_route_info(rte *e, byte *buf, ea_list *attrs) u32 origas; buf += bsprintf(buf, " (%d) [", e->pref); - if (p && as_path_get_first(p->u.ptr, &origas)) + if (p && as_path_get_last(p->u.ptr, &origas)) buf += bsprintf(buf, "AS%u", origas); if (o) buf += bsprintf(buf, "%c", "ie?"[o->u.data]); |