openwrt/package/utils/busybox/patches/301-ip-link-fix-netlink-msg-size.patch
Steven Barth 1fb987e3b8 busybox: fix ip applet and netlink behavior
Signed-off-by: Steven Barth <steven@midlink.org>

SVN-Revision: 46833
2015-09-09 10:38:16 +00:00

12 lines
348 B
Diff

--- a/networking/libiproute/iplink.c
+++ b/networking/libiproute/iplink.c
@@ -470,7 +470,7 @@ static int do_add_or_delete(char **argv,
}
xrtnl_open(&rth);
ll_init_map(&rth);
- if (type_str) {
+ if (type_str && rtm == RTM_NEWLINK) {
struct rtattr *linkinfo = NLMSG_TAIL(&req.n);
addattr_l(&req.n, sizeof(req), IFLA_LINKINFO, NULL, 0);