Unverified Commit 93667e8b authored by openeuler-ci-bot's avatar openeuler-ci-bot Committed by Gitee
Browse files

!6614 [sync] PR-6543: net: ice: Fix potential NULL pointer dereference in ice_bridge_setlink()

parents 4ff0e9f0 a0e76452
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -6531,6 +6531,8 @@ ice_bridge_setlink(struct net_device *dev, struct nlmsghdr *nlh,
	pf_sw = pf->first_sw;
	/* find the attribute in the netlink message */
	br_spec = nlmsg_find_attr(nlh, sizeof(struct ifinfomsg), IFLA_AF_SPEC);
	if (!br_spec)
		return -EINVAL;

	nla_for_each_nested(attr, br_spec, rem) {
		__u16 mode;