From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f65.google.com ([74.125.82.65]:52281 "EHLO mail-wm0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932087AbeDCMqi (ORCPT ); Tue, 3 Apr 2018 08:46:38 -0400 Received: by mail-wm0-f65.google.com with SMTP id g8so9552377wmd.2 for ; Tue, 03 Apr 2018 05:46:38 -0700 (PDT) Date: Tue, 3 Apr 2018 05:46:34 -0700 From: Nathan Chancellor To: Greg Kroah-Hartman Cc: stable@vger.kernel.org Subject: Re: Clang warning fixes for 4.4 and 4.9 Message-ID: <20180403124634.GB13077@flashbox> References: <20180401104446.GA5516@flashbox> <20180403102826.GC17259@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180403102826.GC17259@kroah.com> Sender: stable-owner@vger.kernel.org List-ID: On Tue, Apr 03, 2018 at 12:28:26PM +0200, Greg Kroah-Hartman wrote: > On Sun, Apr 01, 2018 at 03:44:46AM -0700, Nathan Chancellor wrote: > > db0a6fb5d97a ("audit: add tty field to LOGIN event") > > This feels like a new feature, not a clang build warning fix, right? > Why is it needed? > > thanks, > > greg k-h It very well might but it does fix the following Clang warning: ../kernel/audit.c:1894:59: warning: address of array 'tsk->signal->tty->name' will always evaluate to 'true' [-Wpointer-bool-conversion] if (tsk->signal && tsk->signal->tty && tsk->signal->tty->name) ~~ ~~~~~~~~~~~~~~~~~~^~~~ 1 warning generated. I guess a 4.4 only fix would be to remove the '&& tsk->signal->tty->name' but I know you have said many times that just taking the patch in Linus' tree is preferred. Thanks! Nathan