From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 104892 invoked by alias); 25 Aug 2018 14:52:49 -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 104880 invoked by uid 89); 25 Aug 2018 14:52:49 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-3.0 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=H*F:U*tom, HX-HELO:sk:gateway X-HELO: gateway31.websitewelcome.com Received: from gateway31.websitewelcome.com (HELO gateway31.websitewelcome.com) (192.185.143.51) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sat, 25 Aug 2018 14:52:47 +0000 Received: from cm11.websitewelcome.com (cm11.websitewelcome.com [100.42.49.5]) by gateway31.websitewelcome.com (Postfix) with ESMTP id 9B2A64F907 for ; Sat, 25 Aug 2018 09:52:45 -0500 (CDT) Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with SMTP id tZvhfQaudRPojtZvhfrKhT; Sat, 25 Aug 2018 09:52:45 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=Content-Transfer-Encoding:Content-Type:MIME-Version:Message-ID: In-Reply-To:Date:References:Subject:Cc:To:From:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=F4rYtPG3YqsfDsRy9Gcsu8airseSQAbVOYqAzdVoFMw=; b=Nc7i8YYPuPms1dPpVUs969CN9r EVICTk37z609v36HlsrxeOqCeBK8sz7a6rESLusQ2VoryXlsiOJDr3ll3iiMV8HGZ4yNWks7gvCtf 3Ly1RWpPOI2UOqcBUlgUkTZoa; Received: from 75-166-85-72.hlrn.qwest.net ([75.166.85.72]:56946 helo=bapiya) by box5379.bluehost.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.91) (envelope-from ) id 1ftZvh-003iLR-4Y; Sat, 25 Aug 2018 09:52:45 -0500 From: Tom Tromey To: Pedro Alves Cc: Simon Marchi , gdb-patches@sourceware.org Subject: Re: [PATCH v2] Fix 8.2 regression in gdb.python/py-evthreads.exp w/ gdbserver (PR gdb/23379) References: <20180824174616.3306-1-palves@redhat.com> <81f69245-7bad-a9f8-58ef-7f8ead16e71f@ericsson.com> Date: Sat, 25 Aug 2018 14:52:00 -0000 In-Reply-To: (Pedro Alves's message of "Fri, 24 Aug 2018 20:44:13 +0100") Message-ID: <874lfi1osj.fsf@tromey.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-SW-Source: 2018-08/txt/msg00613.txt.bz2 >>>>> "Pedro" =3D=3D Pedro Alves writes: Pedro> * python/py-threadevent.c (get_event_thread): Rename to ... Pedro> (py_get_event_thread): ... this, make extern, add 'ptid' parameter I get this warning now: ../../binutils-gdb/gdb/python/py-threadevent.c: In function =E2=80=98PyObje= ct* py_get_event_thread(ptid_t)=E2=80=99: ../../binutils-gdb/gdb/python/py-threadevent.c:39:3: warning: =E2=80=98pyth= read=E2=80=99 may be used uninitialized in this function [-Wmaybe-uninitial= ized] ... which seems legitimate to me: PyObject *pythread; if (non_stop) { thread_info *thread =3D find_thread_ptid (ptid); if (thread !=3D nullptr) pythread =3D (PyObject *) thread_to_thread_object (thread); // ... else pythread is uninitialized ... } pythread should be set to nullptr where I stuck the comment (or initialized to nullptr). Tom