Re: [PATCH nf-next 5/5] netfilter: nfnetlink_log: just returns error for unknown command

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jan 05, 2016 at 09:34:34AM +0900, Ken-ichirou MATSUZAWA wrote:
> This patch stops processing options for unknown command.
> 
> Signed-off-by: Ken-ichirou MATSUZAWA <chamas@xxxxxxxxxxxxx>
> ---
>  net/netfilter/nfnetlink_log.c |    4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/net/netfilter/nfnetlink_log.c b/net/netfilter/nfnetlink_log.c
> index 6a57f10..643c2d3 100644
> --- a/net/netfilter/nfnetlink_log.c
> +++ b/net/netfilter/nfnetlink_log.c
> @@ -888,7 +888,9 @@ static int nfulnl_recv_config(struct net *net, struct sock *ctnl,
>  			goto out_put;
>  		default:
>  			ret = -ENOTSUPP;
> -			break;
> +			if (inst)
> +				goto out_put;
> +			goto out;

We can simplify this to:

                        goto out_put;

since instance_put() already checks if inst is non-null.

No need to resend, I'll fix this here.

Thanks a lot for following up on this series Ken-ichirou :-).
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux