Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit dfee0a72 authored by Olaf Kirch's avatar Olaf Kirch Committed by David S. Miller
Browse files

[IPV6]: Fix for ipv6_setsockopt NULL dereference

parent aabb601b
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -413,7 +413,7 @@ static int do_ipv6_setsockopt(struct sock *sk, int level, int optname,
		}

		/* routing header option needs extra check */
		if (optname == IPV6_RTHDR && opt->srcrt) {
		if (optname == IPV6_RTHDR && opt && opt->srcrt) {
			struct ipv6_rt_hdr *rthdr = opt->srcrt;
			switch (rthdr->type) {
			case IPV6_SRCRT_TYPE_0: