Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754625AbbKWKUr (ORCPT ); Mon, 23 Nov 2015 05:20:47 -0500 Received: from mail-wm0-f46.google.com ([74.125.82.46]:33857 "EHLO mail-wm0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753785AbbKWKUU (ORCPT ); Mon, 23 Nov 2015 05:20:20 -0500 Subject: Re: nfnetlink warnings To: Borislav Petkov References: <20151123093607.GA5134@pd.tnic> <5652E12E.3070500@profitbricks.com> <20151123095455.GB5134@pd.tnic> Cc: Pablo Neira Ayuso , netfilter-devel@vger.kernel.org, lkml From: Michael Wang Message-ID: <5652E862.7000605@profitbricks.com> Date: Mon, 23 Nov 2015 11:20:18 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 MIME-Version: 1.0 In-Reply-To: <20151123095455.GB5134@pd.tnic> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1163 Lines: 40 On 11/23/2015 10:54 AM, Borislav Petkov wrote: > Hi Michael, > > On Mon, Nov 23, 2015 at 10:49:34AM +0100, Michael Wang wrote: >> Why not just initialized it as NULL, or mark it as uninitialized_var()? > > because I'd like us to save us the redundant NULL initialization in the > if-case. Well, I would vote initialized with NULL, rather than use another else branch to do the same thing. > > I'm not saying any of the approaches are good visually, though. Who > knows, someone might have a better idea like, maybe "Oh, I wanted to > rewrite that code and this handlong is going to be different anyway ..." > or so. Or something to that effect. Who want to do that would take responsibility to make an else branch at that time, but reserve the branch at this moment sounds unnecessary, and not that pretty frankly speaking. > > Btw, please do not top-post. Enjoy ;-) Regards, Michael Wang > > Thanks. > -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/