[PATCH 1/1] addrconf.c: Prevent missing IPv6 addresses

Seth Forshee seth.forshee at canonical.com
Fri Dec 16 19:49:30 UTC 2011


On Fri, Dec 16, 2011 at 11:27:00AM -0800, Brad Figg wrote:
> From: Neil Wilson <neil at brightbox.co.uk>
> 
> BugLink: http://bugs.launchpad.net/bugs/863394
> 
> Commit 5d5619b40c2474de01c64bdf6bb9f1211d3e967a introduced an
> error that prevents certain IPv6 addresses showing up in netlink
> 'dump' listings. This patch backports the corrections from commit
> 234b27c3fd58fc0e15c04dd0fbf4337fac9c2a06

Those breaks had already been added prior to
234b27c3fd58fc0e15c04dd0fbf4337fac9c2a06. You should be able to get
exactly what's needed here by cherry picking
bcd323262a94b14b84341982b90443a76a477861. And as an added bonus, the
indentation will be correct.

> Signed-off-by: Brad Figg <brad.figg at canonical.com>
> ---
>  net/ipv6/addrconf.c |    6 ++++++
>  1 files changed, 6 insertions(+), 0 deletions(-)
> 
> diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
> index 8ac3d09..a5386de 100644
> --- a/net/ipv6/addrconf.c
> +++ b/net/ipv6/addrconf.c
> @@ -3523,6 +3523,8 @@ static int inet6_dump_addr(struct sk_buff *skb, struct netlink_callback *cb,
>  							cb->nlh->nlmsg_seq,
>  							RTM_NEWADDR,
>  							NLM_F_MULTI);
> +				if (err <= 0)
> +				  break;
>  			}
>  			break;
>  		case MULTICAST_ADDR:
> @@ -3536,6 +3538,8 @@ static int inet6_dump_addr(struct sk_buff *skb, struct netlink_callback *cb,
>  							  cb->nlh->nlmsg_seq,
>  							  RTM_GETMULTICAST,
>  							  NLM_F_MULTI);
> +				if (err <= 0)
> +				  break;
>  			}
>  			break;
>  		case ANYCAST_ADDR:
> @@ -3549,6 +3553,8 @@ static int inet6_dump_addr(struct sk_buff *skb, struct netlink_callback *cb,
>  							  cb->nlh->nlmsg_seq,
>  							  RTM_GETANYCAST,
>  							  NLM_F_MULTI);
> +				if (err <= 0)
> +				  break;
>  			}
>  			break;
>  		default:
> -- 
> 1.7.5.4
> 
> 
> -- 
> kernel-team mailing list
> kernel-team at lists.ubuntu.com
> https://lists.ubuntu.com/mailman/listinfo/kernel-team




More information about the kernel-team mailing list