From patchwork Wed Aug 13 09:48:59 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yao Qi X-Patchwork-Id: 2378 Received: (qmail 23661 invoked by alias); 13 Aug 2014 09:52:53 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 23643 invoked by uid 89); 13 Aug 2014 09:52:52 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=0.3 required=5.0 tests=AWL, BAYES_00, URIBL_BLACK autolearn=no version=3.3.2 X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 13 Aug 2014 09:52:51 +0000 Received: from svr-orw-fem-01.mgc.mentorg.com ([147.34.98.93]) by relay1.mentorg.com with esmtp id 1XHVEd-0000Dj-M4 from Yao_Qi@mentor.com ; Wed, 13 Aug 2014 02:52:47 -0700 Received: from SVR-ORW-FEM-03.mgc.mentorg.com ([147.34.97.39]) by svr-orw-fem-01.mgc.mentorg.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.4675); Wed, 13 Aug 2014 02:52:47 -0700 Received: from qiyao.dyndns.org (147.34.91.1) by svr-orw-fem-03.mgc.mentorg.com (147.34.97.39) with Microsoft SMTP Server id 14.2.247.3; Wed, 13 Aug 2014 02:52:46 -0700 Message-ID: <53EB348B.7010408@codesourcery.com> Date: Wed, 13 Aug 2014 17:48:59 +0800 From: Yao Qi User-Agent: Mozilla/5.0 (X11; Linux i686; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 MIME-Version: 1.0 To: Doug Evans CC: Jan Kratochvil , gdb-patches Subject: Re: [patch+7.8?] Fix --with-babeltrace with gcc-4.9.1 References: <20140804202907.GA2608@host2.jankratochvil.net> <53E17E14.8070104@codesourcery.com> <20140812192204.GA13299@host2.jankratochvil.net> <53EAC446.5060409@codesourcery.com> In-Reply-To: X-IsSubscribed: yes On 08/13/2014 11:05 AM, Doug Evans wrote: > I suspect it'll be useful to be able to refer to this reasoning at > some point in the future. > [ref: the "incompatible pointer type" warning is related to the > assignment to scope, not pos]. > Maybe this thread is sufficient, or maybe you could add something to > the commit message. I add something into the commit message as below. Patch is committed to mainline and 7.8 branch. diff --git a/gdb/configure b/gdb/configure index 809326a..874922d 100755 --- a/gdb/configure +++ b/gdb/configure @@ -15344,6 +15344,7 @@ struct bt_iter_pos *pos = bt_iter_get_pos (bt_ctf_get_iter (NULL)); struct bt_ctf_event *event = NULL; const struct bt_definition *scope; + bt_iter_set_pos (bt_ctf_get_iter (NULL), pos); scope = bt_ctf_get_top_level_scope (event, BT_STREAM_EVENT_HEADER); bt_ctf_get_uint64 (bt_ctf_get_field (event, scope, "id")); diff --git a/gdb/configure.ac b/gdb/configure.ac index 70d0964..61919b4 100644 --- a/gdb/configure.ac +++ b/gdb/configure.ac @@ -2437,6 +2437,7 @@ else struct bt_ctf_event *event = NULL; const struct bt_definition *scope; + bt_iter_set_pos (bt_ctf_get_iter (NULL), pos); scope = bt_ctf_get_top_level_scope (event, BT_STREAM_EVENT_HEADER); bt_ctf_get_uint64 (bt_ctf_get_field (event, scope, "id"));