On Thu, Dec 14, 2017 at 08:40:20PM +0100, Phil Sutter wrote: > The code works fine as-is, but if reg_type == DATA_VALUE && > output_format == NFTNL_OUTPUT_XML, we fall through to DATA_CHAIN case > and therefore pointlessly check output_format again. > > Signed-off-by: Phil Sutter <phil@xxxxxx> > --- > src/expr/data_reg.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/src/expr/data_reg.c b/src/expr/data_reg.c > index a246952f7f01b..c087d792a8af6 100644 > --- a/src/expr/data_reg.c > +++ b/src/expr/data_reg.c > @@ -207,6 +207,7 @@ int nftnl_data_reg_snprintf(char *buf, size_t size, > default: > break; > } > + break; > case DATA_VERDICT: > case DATA_CHAIN: > switch(output_format) { I'm going to add a break also at the end of 'case DATA_CHAIN:', recent gcc can spot warning on implicit fall through without comments, so let's fix that spot too. Applied, thanks! -- 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