From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 64131 invoked by alias); 10 Feb 2020 14:19:21 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 64122 invoked by uid 89); 10 Feb 2020 14:19:21 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-12.7 required=5.0 tests=AWL,BAYES_00,SPF_PASS autolearn=ham version=3.3.1 spammy=10022020, 10-02-2020 X-HELO: mx2.suse.de Received: from mx2.suse.de (HELO mx2.suse.de) (195.135.220.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 10 Feb 2020 14:19:20 +0000 Received: from relay2.suse.de (unknown [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 19FD7B1CF; Mon, 10 Feb 2020 14:19:18 +0000 (UTC) Subject: Re: [PATCH][gdb] Fix -Wstrict-null-sentinel warnings To: Simon Marchi , Tom Tromey Cc: Christian Biesinger , gdb-patches References: <20200207113429.GA6532@delia> <7a8ea599-5254-46be-95b3-fa2af134656d@simark.ca> <99e7c8e5-8662-5b66-9d05-6ec3581b08bd@suse.de> <87v9ofx4s8.fsf@tromey.com> <5588f044-4f8b-ff32-070a-aacf7932671f@suse.de> <0e65dcad-227e-1612-7d7d-f6de9db40493@simark.ca> From: Tom de Vries Message-ID: <21aebb7c-51bf-8ce9-f383-1c1421327578@suse.de> Date: Mon, 10 Feb 2020 14:19:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 MIME-Version: 1.0 In-Reply-To: <0e65dcad-227e-1612-7d7d-f6de9db40493@simark.ca> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2020-02/txt/msg00284.txt.bz2 On 10-02-2020 15:08, Simon Marchi wrote: > On 2020-02-10 5:18 a.m., Tom de Vries wrote: >> [ was: Re: [PATCH][gdb] Mention CU offset for if verbose ] >> >> On 09-02-2020 14:35, Tom Tromey wrote: >>>>>>>> "Tom" == Tom de Vries writes: >>> >>> Tom> + debug_filename.reset (concat (artificial, "@", >>> Tom> + sect_offset_str (per_cu->sect_off), NULL)); >>> >>> When passing NULL to concat, you either need nullptr or (char *) NULL. >> >> Fixed in attached patch. >> >> OK for trunk? > > I think we usually put a space after the cast: > > (char *) NULL > Ack, committed with that fixed. Thanks, - Tom > Also, if we want to enforce this warning, it should be added to gdb/warning.m4. Makefiles > in gdb/ and gdbserver/ should be re-generated. gdbsupport/ doesn't use AM_GDB_WARNINGS at > the moment.