Re: [PATCH nft 2/2] src: store expression as set key instead of data type

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

 



On Tue, Sep 19, 2017 at 02:49:54PM +0200, Florian Westphal wrote:
> @@ -1023,7 +1036,8 @@ static int list_member_evaluate(struct eval_ctx *ctx, struct expr **expr)
>  	return err;
>  }
>  
> -static int expr_evaluate_concat(struct eval_ctx *ctx, struct expr **expr)
> +static int expr_evaluate_concat(struct eval_ctx *ctx, struct expr **expr,
> +				bool evaluate)

Hm, why this boolean as parameter?

>  {
>  	const struct datatype *dtype = ctx->ectx.dtype, *tmp;
>  	uint32_t type = dtype ? dtype->type : 0, ntype = 0;
> @@ -1044,7 +1058,7 @@ static int expr_evaluate_concat(struct eval_ctx *ctx, struct expr **expr)
>  			tmp = concat_subtype_lookup(type, --off);
>  		expr_set_context(&ctx->ectx, tmp, tmp->size);
>  
> -		if (list_member_evaluate(ctx, &i) < 0)
> +		if (evaluate && list_member_evaluate(ctx, &i) < 0)
>  			return -1;
>  		flags &= i->flags;
>  
--
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