From patchwork Mon Oct 14 14:57:44 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Tromey X-Patchwork-Id: 34939 Received: (qmail 54691 invoked by alias); 14 Oct 2019 14:57:50 -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 54584 invoked by uid 89); 14 Oct 2019 14:57:49 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-22.8 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, SPF_PASS autolearn=ham version=3.3.1 spammy=HContent-Transfer-Encoding:8bit X-HELO: rock.gnat.com Received: from rock.gnat.com (HELO rock.gnat.com) (205.232.38.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 14 Oct 2019 14:57:47 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id 7DD3811627F; Mon, 14 Oct 2019 10:57:46 -0400 (EDT) Received: from rock.gnat.com ([127.0.0.1]) by localhost (rock.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id cNMmOoyZyIbo; Mon, 14 Oct 2019 10:57:46 -0400 (EDT) Received: from murgatroyd.Home (174-29-53-230.hlrn.qwest.net [174.29.53.230]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by rock.gnat.com (Postfix) with ESMTPSA id 29C5C116207; Mon, 14 Oct 2019 10:57:46 -0400 (EDT) From: Tom Tromey To: gdb-patches@sourceware.org Cc: Tom Tromey Subject: [PATCH 2/2] Use %x when printing the TID Date: Mon, 14 Oct 2019 08:57:44 -0600 Message-Id: <20191014145744.5535-3-tromey@adacore.com> In-Reply-To: <20191014145744.5535-1-tromey@adacore.com> References: <20191014145744.5535-1-tromey@adacore.com> MIME-Version: 1.0 One spot in windows-nat.c uses %ld to print the TID, but all other spots use %x, as does the infrun logging. This makes it unnecessarily hard to tell which other log messages correspond to this one. This patch changes the one outlier to use %x. gdb/ChangeLog 2019-10-14 Tom Tromey * windows-nat.c (windows_nat_target::resume): Use %x when logging TID. --- gdb/ChangeLog | 5 +++++ gdb/windows-nat.c | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/gdb/windows-nat.c b/gdb/windows-nat.c index df44994c95a..a756913cabf 100644 --- a/gdb/windows-nat.c +++ b/gdb/windows-nat.c @@ -1447,8 +1447,8 @@ windows_nat_target::resume (ptid_t ptid, int step, enum gdb_signal sig) last_sig = GDB_SIGNAL_0; - DEBUG_EXEC (("gdb: windows_resume (pid=%d, tid=%ld, step=%d, sig=%d);\n", - ptid.pid (), ptid.tid (), step, sig)); + DEBUG_EXEC (("gdb: windows_resume (pid=%d, tid=0x%x, step=%d, sig=%d);\n", + ptid.pid (), (unsigned) ptid.tid (), step, sig)); /* Get context for currently selected thread. */ th = thread_rec (inferior_ptid.tid (), FALSE);