Re: [PATCH nft WIP] jump: Allow jump to a variable when using nft input files

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

 



On Sun, May 12, 2019 at 08:16:19PM +0200, Fernando Fernandez Mancera wrote:
> diff --git a/src/parser_bison.y b/src/parser_bison.y
> index 9aea652..5f61b14 100644
> --- a/src/parser_bison.y
> +++ b/src/parser_bison.y
[...]
> @@ -3841,6 +3841,14 @@ verdict_expr		:	ACCEPT
>  			}
>  			;
> 
> +chain_expr		:	identifier
> +			{
> +				$$ = constant_expr_alloc(&@$, &string_type,
> +							 BYTEORDER_HOST_ENDIAN,
> +							 sizeof($1) * BITS_PER_BYTE, &$1);

I think you should use NFT_NAME_MAXLEN instead of sizeof($1) here.

> +			}
> +			;
> +
>  meta_expr		:	META	meta_key
>  			{
>  				$$ = meta_expr_alloc(&@$, $2);
> -- 
> 2.20.1



[Index of Archives]     [Netfitler Users]     [Berkeley Packet Filter]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux