Blame SOURCES/0011-iprule-Fix-destination-prefix-output.patch

930fb9
From deef2321cf38ef0314bea307dbc27d376ad39624 Mon Sep 17 00:00:00 2001
930fb9
From: Phil Sutter <psutter@redhat.com>
930fb9
Date: Thu, 13 Sep 2018 20:45:38 +0200
930fb9
Subject: [PATCH] iprule: Fix destination prefix output
930fb9
930fb9
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1623503
930fb9
Upstream Status: iproute2.git commit 1a75322c5a8de
930fb9
930fb9
commit 1a75322c5a8dee6e1ed0017d76c87ef85c505b98
930fb9
Author: Stefan Bader <stefan.bader@canonical.com>
930fb9
Date:   Tue Aug 28 16:27:29 2018 +0200
930fb9
930fb9
    iprule: Fix destination prefix output
930fb9
930fb9
    When adding support for JSON output the new code for printing
930fb9
    the destination prefix adds a stray blank character before
930fb9
    the bitmask. This causes some user-space parsing to fail.
930fb9
930fb9
    Current output:
930fb9
      ...: from x.x.x.x/l to y.y.y.y /l
930fb9
    Previous output:
930fb9
      ...: from x.x.x.x/l to y.y.y.y/l
930fb9
930fb9
    Fixes: 0dd4ccc5 "iprule: add json support"
930fb9
    Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
930fb9
    Acked-by: Luca Boccassi <bluca@debian.org>
930fb9
    Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
930fb9
---
930fb9
 ip/iprule.c | 2 +-
930fb9
 1 file changed, 1 insertion(+), 1 deletion(-)
930fb9
930fb9
diff --git a/ip/iprule.c b/ip/iprule.c
930fb9
index 8b94214..744d6d8 100644
930fb9
--- a/ip/iprule.c
930fb9
+++ b/ip/iprule.c
930fb9
@@ -239,7 +239,7 @@ int print_rule(const struct sockaddr_nl *who, struct nlmsghdr *n, void *arg)
930fb9
 
930fb9
 		print_string(PRINT_FP, NULL, "to ", NULL);
930fb9
 		print_color_string(PRINT_ANY, ifa_family_color(frh->family),
930fb9
-				   "dst", "%s ", dst);
930fb9
+				   "dst", "%s", dst);
930fb9
 		if (frh->dst_len != host_len)
930fb9
 			print_uint(PRINT_ANY, "dstlen", "/%u ", frh->dst_len);
930fb9
 		else
930fb9
-- 
930fb9
1.8.3.1
930fb9