]> git.puffer.fish Git - mirror/frr.git/commit
bgpd: fix version attribute is an int, not a string 17513/head
authorPhilippe Guibert <philippe.guibert@6wind.com>
Mon, 25 Nov 2024 21:47:21 +0000 (22:47 +0100)
committerMergify <37929162+mergify[bot]@users.noreply.github.com>
Tue, 26 Nov 2024 13:30:21 +0000 (13:30 +0000)
commitcd238c71bb037289ade2768709e9b42d9f0a8c04
tree226145c9e8c8d461d1a284664f0806fdbf0e907c
parent0268aef6ad215efb469b27bff30dfb43aa265f97
bgpd: fix version attribute is an int, not a string

The json display of the version attribute is originally an
integer. It has changed, most probably mistakenly.

> {
>   "vrfId": 7,
>   "vrfName": "vrf1",
>   "tableVersion": 3,
>   "routerId": "192.0.2.1",
>   "defaultLocPrf": 100,
>   "localAS": 65500,
>   "routes": {
>     "172.31.0.1/32": {
>       "prefix": "172.31.0.1/32",
>       "version": "1", <--- int or string ??

Let us fix it, by using the integer display instead.

Fixes: f9f2d188e398 ("bgpd: fix 'json detail' output structure")
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
(cherry picked from commit c5d7815cccb92c192ca6b752843b8b827a607b53)
bgpd/bgp_route.c