From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: Adjust gtkutil.c to build with gcc (GCC) 11.2.1 with -Wanalyzer-null-argument Date: Wed, 01 Sep 2021 16:36:49 +0300 Message-ID: <83czpsquxa.fsf@gnu.org> References: <83k0k0qy64.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="10890"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Alexander Kuleshov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed Sep 01 15:37:32 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mLQQl-0002Su-Nj for ged-emacs-devel@m.gmane-mx.org; Wed, 01 Sep 2021 15:37:31 +0200 Original-Received: from localhost ([::1]:58628 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mLQQk-0002bA-O7 for ged-emacs-devel@m.gmane-mx.org; Wed, 01 Sep 2021 09:37:30 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:52708) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mLQQ9-0001u3-GG for emacs-devel@gnu.org; Wed, 01 Sep 2021 09:36:53 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:49364) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mLQQ8-0005fv-Ah; Wed, 01 Sep 2021 09:36:52 -0400 Original-Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:2635 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mLQQ7-00011y-UB; Wed, 01 Sep 2021 09:36:52 -0400 In-Reply-To: (message from Alexander Kuleshov on Wed, 1 Sep 2021 18:44:34 +0600) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:273659 Archived-At: > From: Alexander Kuleshov > Date: Wed, 1 Sep 2021 18:44:34 +0600 > Cc: emacs-devel > > On Wed, Sep 1, 2021 at 6:26 PM Eli Zaretskii wrote: > > > > > From: Alexander Kuleshov > > > Date: Wed, 1 Sep 2021 16:52:55 +0600 > > > > > > gtkutil.c: In function ‘xg_item_label_same_p’: > > > gtkutil.c:2936:54: error: use of NULL where non-null expected > > > [CWE-476] [-Werror=analyzer-null-argument] > > > 2936 | && ((!old_label && !utf8_label) || strcmp > > > (utf8_label, old_label) == 0)); > > > > Isn't this a GCC bug? > > hmm, yes, possibly. And forget about attachment, I was wrong with > `(!old_label == !utf8_label) ||` part. So maybe report it to their Bugzilla? If it isn't a bug, perhaps they will explain to us what is wrong with our code? Thanks.