summaryrefslogtreecommitdiff
path: root/nest/rt-attr.c
diff options
context:
space:
mode:
authorOndrej Zajicek <santiago@crfreenet.org>2009-07-23 16:06:25 +0200
committerOndrej Zajicek <santiago@crfreenet.org>2009-07-23 16:06:25 +0200
commit2f6483cd312ffd7ef055099ce801fb8f437d9abe (patch)
treedd4d468a17017a5b1372057be9bcc40536089a3c /nest/rt-attr.c
parentf0333f44a5a4bec9f3978a90cf7eda1b0a2ec151 (diff)
Adds %R printf directive for Router ID.
Diffstat (limited to 'nest/rt-attr.c')
-rw-r--r--nest/rt-attr.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/nest/rt-attr.c b/nest/rt-attr.c
index 2318f801..de63198e 100644
--- a/nest/rt-attr.c
+++ b/nest/rt-attr.c
@@ -419,11 +419,7 @@ ea_format(eattr *e, byte *buf)
bsprintf(buf, "%I", *(ip_addr *) ad->data);
break;
case EAF_TYPE_ROUTER_ID:
- bsprintf(buf, "%d.%d.%d.%d",
- (e->u.data >> 24) & 0xff,
- (e->u.data >> 16) & 0xff,
- (e->u.data >> 8) & 0xff,
- e->u.data & 0xff);
+ bsprintf(buf, "%R", e->u.data);
break;
case EAF_TYPE_AS_PATH:
as_path_format(ad, buf, end - buf);