Re: [PATCH libnftnl] src: consolidate XML/JSON exportation

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

 



On Mon, Nov 10, 2014 at 11:22:07AM +0100, Pablo Neira Ayuso wrote:
> Add new buffer class to consolidate the existing code to export objects
> in XML/JSON and use it. We save ~700 LOC with this change.
> 
> The rule and set objects are not yet consolidated. It seems this would
> require some specific glue code per representation type since lists are
> arranged differently.
> 
> Signed-off-by: Pablo Neira Ayuso <pablo@xxxxxxxxxxxxx>
> ---
> @Arturo, @Alvaro: It seems to me that the XML and JSON are currently not
> round-trippable due to (at least) this difference:
> 
> <expr type="meta">...</expr>
> "expr":[{"type":"meta",...
> 
> Two choices:
> 
> * XML uses <expr><type>meta</type>...</expr>.
> * JSON uses "expr":[{"-type":"meta",...
> 
> in any case, I think we'll have to break the representation for one of
> them to fix this.

I accidentally sent an old version of this patch. This change has
spotted and fixed many inconsistencies in the output of expressions.
I'll resend the newer patch again.
--
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