From a0e9ab24a26b91d5dd54e85c72f03587f61ee109 Mon Sep 17 00:00:00 2001 From: Costas Drogos Date: Tue, 6 Jun 2023 22:56:32 +0200 Subject: [PATCH] cmd/gobgp: fix parseEvpnEthernetAutoDiscoveryArgs esi-label follows the format: [esi-label [single-active | all-active]] extractReserved() splits by spaces, returning a list for esi-label, hence failing the type check. Change its parameter value type to paramList to be able to accomodate cases such as "... esi-label 400 single-active". --- cmd/gobgp/global.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/gobgp/global.go b/cmd/gobgp/global.go index 9d36da174..226c640cb 100644 --- a/cmd/gobgp/global.go +++ b/cmd/gobgp/global.go @@ -470,7 +470,7 @@ func parseEvpnEthernetAutoDiscoveryArgs(args []string) (bgp.AddrPrefixInterface, "rd": paramSingle, "rt": paramList, "encap": paramSingle, - "esi-label": paramSingle}) + "esi-label": paramList}) if err != nil { return nil, nil, err }