On 3/8/20 14:52, Phil Sutter wrote:
On Sat, Aug 01, 2020 at 09:27:30PM +0200, Pablo Neira Ayuso wrote:
We need an unified way to deal with --json --echo, whether the input
is native nft or json syntax.
We don't need, but seems we want. We have JSON output and JSON echo for
a while now and code for both is distinct. I fail to see why this was OK
but is no longer. From my perspective, Jose simply failed to see that
JSON output code should be used for JSON echo if input is not JSON.
I will send a v4 for this patch honoring separate cases.
Only outputting JSON command objects when input has been native instead
of JSON, for the latter the behavior is kept intact and no
json_cmd_assoc is touched. I think that's what we are looking for right
now. This shouldn't interfere with firewalld, right?.
Regards.