
< 	if (rt != net->ipv6.ip6_null_entry) {
---
> 	if (!net || !net->ipv6.ip6_null_entry)
> 		return -EINVAL;
> 	if (rt != net->ipv6.ip6_null_entry) {
