From: Philippe Guibert Date: Tue, 14 Feb 2017 10:54:33 +0000 (+0100) Subject: lib: prefix2str initialises incoming buffer in case erroneous EVPN pfx X-Git-Tag: frr-3.0-branchpoint~29^2~5 X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=43b4350ca7efa79f393cf68c62b5be5614ac9a11;p=mirror%2Ffrr.git lib: prefix2str initialises incoming buffer in case erroneous EVPN pfx In the case, evpn prefix is requested to be transformed into string, and if the evpn prefix is not an evpn route type 5 entry, then the prefix is returning an initialised string that mentions the vpn prefix is unknown. Signed-off-by: Philippe Guibert --- diff --git a/lib/prefix.c b/lib/prefix.c index 8948a2ac19..19cf7dd8f9 100644 --- a/lib/prefix.c +++ b/lib/prefix.c @@ -880,6 +880,10 @@ prefix2str (union prefixconstptr pu, char *str, int size) buf, PREFIX2STR_BUFFER), p->prefixlen); } + else + { + sprintf (str, "UNK AF_ETHER prefix"); + } break; default: sprintf (str, "UNK prefix");