diff options
author | Thomas Haller <thaller@redhat.com> | 2022-05-03 16:59:22 (GMT) |
---|---|---|
committer | Thomas Haller <thaller@redhat.com> | 2022-05-03 17:03:37 (GMT) |
commit | 9b0493646c20f3eecdf664e7e00c6c9162e04fba (patch) | |
tree | fd4d31e048d221e073f74c1b7537e48e073798bb | |
parent | 2effffe7979dda638108fba26b763fa5acd6edac (diff) | |
download | libnl-9b0493646c20f3eecdf664e7e00c6c9162e04fba.zip libnl-9b0493646c20f3eecdf664e7e00c6c9162e04fba.tar.gz libnl-9b0493646c20f3eecdf664e7e00c6c9162e04fba.tar.bz2 |
route: fix crash caused by parse_multipath() by wrong free()
https://bugzilla.redhat.com/show_bug.cgi?id=2081279
Fixes: b50be8fa869b ('rtnl/route: use cleanup attribute in "lib/route/route_obj.c"')
-rw-r--r-- | lib/route/route_obj.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/route/route_obj.c b/lib/route/route_obj.c index 4fdd23c..9441b77 100644 --- a/lib/route/route_obj.c +++ b/lib/route/route_obj.c @@ -1102,7 +1102,7 @@ static int parse_multipath(struct rtnl_route *route, struct nlattr *attr) } } - rtnl_route_add_nexthop(route, nh); + rtnl_route_add_nexthop(route, _nl_steal_pointer(&nh)); tlen -= RTNH_ALIGN(rtnh->rtnh_len); rtnh = RTNH_NEXT(rtnh); } |