From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 7D796385841F; Tue, 23 Jan 2024 16:25:48 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 7D796385841F DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1706027148; bh=4XUxWHKc4sM/fVsJCpHSrsuHRMZP6k9R1wE3I8nTLi4=; h=From:To:Subject:Date:In-Reply-To:References:From; b=VVXUAAi9GZfnbIZqw1wzPI9z/sIX3nJQMEbT8NYui6bLAujCBTw6kVoBcaTBJr0I4 0mmNRXxryyZ/EGKELxpCr0K4mhCASpLYNStIZCVB/uCoJ1nce0TSYi1Q73J/MupqmX Cq7NTyB4zogegjdq8+Lstn0OXcrSjOeAoHjgQf9k= From: "cvs-commit at gcc dot gnu.org" To: gdb-prs@sourceware.org Subject: [Bug gdb/31256] Crash with basic 'list .' Date: Tue, 23 Jan 2024 16:25:48 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gdb X-Bugzilla-Component: gdb X-Bugzilla-Version: HEAD X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: RESOLVED X-Bugzilla-Resolution: FIXED X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://sourceware.org/bugzilla/show_bug.cgi?id=3D31256 --- Comment #9 from Sourceware Commits --- The gdb-14-branch branch has been updated by Guinevere Larsen : https://sourceware.org/git/gitweb.cgi?p=3Dbinutils-gdb.git;h=3D4fe1a40c7c46= 4bde0212aa859774fe59fb71ccfe commit 4fe1a40c7c464bde0212aa859774fe59fb71ccfe Author: Guinevere Larsen Date: Mon Jan 22 10:13:52 2024 +0100 gdb: fix "list ." related crash When a user attempts to use the "list ." command with an inferior that doesn't have debug symbols, GDB would crash. This was reported as PR gdb/31256. The crash would happen when attempting to get the current symtab_and_li= ne for the stop location, because the symtab would return a null pointer and we'd attempt to dereference it to print the line. This commit fixes that by checking for an empty symtab and erroring out of the function if it happens. Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=3D31256 Approved-By: Tom Tromey --=20 You are receiving this mail because: You are on the CC list for the bug.=