Re: [nft PATCH] json: Fix compile error

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

 



On Tue, Aug 28, 2018 at 10:26:56PM +0200, Phil Sutter wrote:
> Commit 9e45a28ca467f ("src: honor /etc/services") broke compiling with
> JSON support enabled: inet_service_type_print() is not suited for
> converting inet_service datatype into JSON at all.
> 
> In order to avoid having to replicate the port value resolving into
> human-readable name in inet_service_type_json(), just return a numeric
> value. At least for JSON output, this probably makes most sense either
> way since the output is expected to be parsed by scripts which have an
> easier time with numers than names anyway.

Thanks for fixing up this Phil, applied.

> Fixes: 9e45a28ca467f ("src: honor /etc/services")
> Signed-off-by: Phil Sutter <phil@xxxxxx>
> ---
> Unless there are objections, I will later follow-up with a patch to
> convert remaining human readable values into numeric ones in JSON
> regardless of numeric output or not. This is just a quick fix to unbreak
> the build.

Please, go ahead.



[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux