From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 4B4D73858D35; Mon, 23 Aug 2021 10:08:47 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4B4D73858D35 From: "cvs-commit at gcc dot gnu.org" To: gdb-prs@sourceware.org Subject: [Bug gdb/26880] hex instead of filename printed in error message Date: Mon, 23 Aug 2021 10:08:46 +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: NEW X-Bugzilla-Resolution: 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 X-BeenThere: gdb-prs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-prs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 23 Aug 2021 10:08:47 -0000 https://sourceware.org/bugzilla/show_bug.cgi?id=3D26880 --- Comment #9 from cvs-commit at gcc dot gnu.org --- The master branch has been updated by Tom de Vries : https://sourceware.org/git/gitweb.cgi?p=3Dbinutils-gdb.git;h=3Da9680e0e54cf= d8a12ddb1a583b4acb96dc2bbdbd commit a9680e0e54cfd8a12ddb1a583b4acb96dc2bbdbd Author: Tom de Vries Date: Mon Aug 23 12:08:25 2021 +0200 [gdb] Fix 'not in executable format' error message With trying to load a non-executable file into gdb, we run into PR26880: ... $ gdb -q -batch test.c "0x7ffc87bfc8d0s": not in executable format: \ file format not recognized ... The problem is caused by using %ps in combination with the error functi= on (note that confusingly, it does work in combination with the warning function). Fix this by using plain "%s" instead. Tested on x86_64-linux. gdb/ChangeLog: 2021-08-22 Tom de Vries PR gdb/26880 * gdb/exec.c (exec_file_attach): Use %s instead of %ps in call = to error function. gdb/testsuite/ChangeLog: 2021-08-22 Tom de Vries PR gdb/26880 * gdb.base/non-executable.exp: New file. --=20 You are receiving this mail because: You are on the CC list for the bug.=