From: claudio Date: Mon, 12 Aug 2024 09:05:28 +0000 (+0000) Subject: Print min-version of a RTR session. X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=282ccd24f826a9c097e891566b1655c9030dfd5a;p=openbsd Print min-version of a RTR session. OK tb@ --- diff --git a/usr.sbin/bgpctl/output.c b/usr.sbin/bgpctl/output.c index 247a66d3756..e75ec7a2266 100644 --- a/usr.sbin/bgpctl/output.c +++ b/usr.sbin/bgpctl/output.c @@ -1,4 +1,4 @@ -/* $OpenBSD: output.c,v 1.51 2024/05/22 08:42:34 claudio Exp $ */ +/* $OpenBSD: output.c,v 1.52 2024/08/12 09:05:28 claudio Exp $ */ /* * Copyright (c) 2003 Henning Brauer @@ -1128,8 +1128,9 @@ show_rtr(struct ctl_show_rtr *rtr) if (rtr->local_addr.aid != AID_UNSPEC) printf(" Local Address: %s\n", log_addr(&rtr->local_addr)); if (rtr->session_id != -1) - printf(" Version: %u Session ID: %d Serial #: %u\n", - rtr->version, rtr->session_id, rtr->serial); + printf(" Version: %u min %u Session ID: %d Serial #: %u\n", + rtr->version, rtr->min_version, rtr->session_id, + rtr->serial); printf(" Refresh: %u, Retry: %u, Expire: %u\n", rtr->refresh, rtr->retry, rtr->expire); diff --git a/usr.sbin/bgpctl/output_json.c b/usr.sbin/bgpctl/output_json.c index e0190966e5f..daf865a1b4b 100644 --- a/usr.sbin/bgpctl/output_json.c +++ b/usr.sbin/bgpctl/output_json.c @@ -1,4 +1,4 @@ -/* $OpenBSD: output_json.c,v 1.44 2024/05/22 08:42:34 claudio Exp $ */ +/* $OpenBSD: output_json.c,v 1.45 2024/08/12 09:05:28 claudio Exp $ */ /* * Copyright (c) 2020 Claudio Jeker @@ -963,6 +963,7 @@ json_rtr(struct ctl_show_rtr *rtr) if (rtr->session_id != -1) { json_do_uint("version", rtr->version); + json_do_uint("minimal_version", rtr->min_version); json_do_uint("session_id", rtr->session_id); json_do_uint("serial", rtr->serial); }