[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20171219082753.4e271cf9@xeon-e3>
Date: Tue, 19 Dec 2017 08:27:53 -0800
From: Stephen Hemminger <stephen@...workplumber.org>
To: Alexander Zubkov <green@....ru>
Cc: zubkov318@...il.com, netdev@...r.kernel.org
Subject: Re: [PATCH] iproute: "list/flush/save default" selected all of the
routes
On Sun, 17 Dec 2017 12:09:00 +0100
Alexander Zubkov <green@....ru> wrote:
> When running "ip route list default" and not specifying address family,
> one will get all of the routes instead of just default only. The same
> is for "exact default" and "match default".
>
> It behaves in such a way because default route with unspecified family
> has the same all-zeroes value like no prefix specified at all. Thus
> following code blindly ignores the fact, that prefix was actually
> specified.
>
> This patch adds the flag PREFIXLEN_SPECIFIED to the default route too.
> And then checks its value when filtering routes.
>
> Signed-off-by: Alexander Zubkov <green@....ru>
Applied, thanks Alexander
Powered by blists - more mailing lists