[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1334071226-17865-1-git-send-email-jorge@dti2.net>
Date: Tue, 10 Apr 2012 17:20:26 +0200
From: "Jorge Boncompte [DTI2]" <jorge@...2.net>
To: netdev@...r.kernel.org
Cc: shemminger@...tta.com, "Jorge Boncompte [DTI2]" <jorge@...2.net>
Subject: [PATCH] iproute: show metrics as an unsigned value
From: "Jorge Boncompte [DTI2]" <jorge@...2.net>
Avoids showing negative metrics.
Signed-off-by: Jorge Boncompte [DTI2] <jorge@...2.net>
---
ip/iproute.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/ip/iproute.c b/ip/iproute.c
index c97f979..2d15c01 100644
--- a/ip/iproute.c
+++ b/ip/iproute.c
@@ -404,7 +404,7 @@ int print_route(const struct sockaddr_nl *who, struct nlmsghdr *n, void *arg)
abuf, sizeof(abuf)));
}
if (tb[RTA_PRIORITY])
- fprintf(fp, " metric %d ", *(__u32*)RTA_DATA(tb[RTA_PRIORITY]));
+ fprintf(fp, " metric %u ", *(__u32*)RTA_DATA(tb[RTA_PRIORITY]));
if (r->rtm_flags & RTNH_F_DEAD)
fprintf(fp, "dead ");
if (r->rtm_flags & RTNH_F_ONLINK)
--
1.7.8.3
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists