From e29499b8e99af5e65a759f80aef6a9b35c15b10a Mon Sep 17 00:00:00 2001 From: Julian Anastasov Date: Fri, 20 Jul 2012 12:02:08 +0300 Subject: [PATCH] --- yaml --- r: 315740 b: refs/heads/master c: 521f549097a79dc55e18c3bc752ef2127ad70ac5 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/net/ipv4/route.c | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index 3faa9bf076be..fae8366944d2 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: e4bce0f288bafd8505ba5ce9c5284a4478f1b725 +refs/heads/master: 521f549097a79dc55e18c3bc752ef2127ad70ac5 diff --git a/trunk/net/ipv4/route.c b/trunk/net/ipv4/route.c index 9f7ffbe201c9..d547f6fae20d 100644 --- a/trunk/net/ipv4/route.c +++ b/trunk/net/ipv4/route.c @@ -2909,6 +2909,7 @@ static int rt_fill_info(struct net *net, struct nlmsghdr *nlh; unsigned long expires = 0; u32 error; + u32 metrics[RTAX_MAX]; nlh = nlmsg_put(skb, pid, seq, event, sizeof(*r), flags); if (nlh == NULL) @@ -2953,7 +2954,10 @@ static int rt_fill_info(struct net *net, nla_put_be32(skb, RTA_GATEWAY, rt->rt_gateway)) goto nla_put_failure; - if (rtnetlink_put_metrics(skb, dst_metrics_ptr(&rt->dst)) < 0) + memcpy(metrics, dst_metrics_ptr(&rt->dst), sizeof(metrics)); + if (rt->rt_pmtu) + metrics[RTAX_MTU - 1] = rt->rt_pmtu; + if (rtnetlink_put_metrics(skb, metrics) < 0) goto nla_put_failure; if (rt->rt_mark &&