From mboxrd@z Thu Jan 1 00:00:00 1970 From: Patrick McHardy Subject: Re: [PATCH nft] segtree: add new segtree debugging option Date: Wed, 15 Jan 2014 14:48:10 +0000 Message-ID: <20140115144810.GA32750@macbook.localnet> References: <1389788704-21079-1-git-send-email-pablo@netfilter.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: netfilter-devel@vger.kernel.org To: Pablo Neira Ayuso Return-path: Received: from stinky.trash.net ([213.144.137.162]:45457 "EHLO stinky.trash.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751760AbaAOOsd (ORCPT ); Wed, 15 Jan 2014 09:48:33 -0500 Content-Disposition: inline In-Reply-To: <1389788704-21079-1-git-send-email-pablo@netfilter.org> Sender: netfilter-devel-owner@vger.kernel.org List-ID: On Wed, Jan 15, 2014 at 01:25:04PM +0100, Pablo Neira Ayuso wrote: > Currently, nft displays the debugging information if it's compiled with > --enable-debug (which seems a good idea) and when intervals are used > in maps. Add a new option to enable debugging to segtree, so we only > get this information when explicitly requested. > > Signed-off-by: Pablo Neira Ayuso > --- > We need this in master to avoid inconditional display of the > debugging information when --enable-debug is passed at configuration > / compilation time. I'm aware this patch conflicts with next-3.14, > that conflict should be easy to resolve. Looks good, thanks, I wanted to change this myself. A few more things about debugging, some are easy, some might be a bit more work: - we should use stdout for netlink rule debugging - netlink rule debugging is very very verbose since it dumps the entire netlink message. I'd prefer to only have the netlink expressions ([meta load ...]) and have the netlink message as another option. It keeps scrolling everything off the screen. - netlink message debugging colors break in less. We should check for isatty().