public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
From: "cvs-commit at gcc dot gnu.org" <sourceware-bugzilla@sourceware.org>
To: gdb-prs@sourceware.org
Subject: [Bug gdb/27773] 'Dump memory' command aborted in GDB
Date: Mon, 26 Apr 2021 15:28:52 +0000	[thread overview]
Message-ID: <bug-27773-4717-NmYoR7ELIT@http.sourceware.org/bugzilla/> (raw)
In-Reply-To: <bug-27773-4717@http.sourceware.org/bugzilla/>

https://sourceware.org/bugzilla/show_bug.cgi?id=27773

--- Comment #1 from cvs-commit at gcc dot gnu.org <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Simon Marchi <simark@sourceware.org>:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=bea3329b76cf131ad4ac27acb6728b38984998b9

commit bea3329b76cf131ad4ac27acb6728b38984998b9
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Mon Apr 26 11:27:07 2021 -0400

    gdb: check result of gdb_fopen_cloexec in dump_binary_file

    Bug 27773 shows that passing a filename in a non-existent directory to
    the "dump binary" command leads to a gdb crash.  This is because the
    gdb_fopen_cloexec in dump_binary_file fails (returns nullptr) and the
    return value is not checked.  Fix that by erroring out if
    gdb_fopen_cloexec fails.

    gdb/ChangeLog:

            PR gdb/27773
            * cli/cli-dump.c (dump_binary_file): Check result of
            gdb_fopen_cloexec.

    gdb/testsuite/ChangeLog:

            PR gdb/27773
            * gdb.base/dump.exp: Test dump to non-existent dir.

    Change-Id: Iea89a3bf9e6b9dcc31142faa5ae17bc855759328

-- 
You are receiving this mail because:
You are on the CC list for the bug.

  reply	other threads:[~2021-04-26 15:28 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-24  3:36 [Bug gdb/27773] New: " 1179317825 at qq dot com
2021-04-26 15:28 ` cvs-commit at gcc dot gnu.org [this message]
2021-04-26 15:33 ` [Bug gdb/27773] " simark at simark dot ca

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-27773-4717-NmYoR7ELIT@http.sourceware.org/bugzilla/ \
    --to=sourceware-bugzilla@sourceware.org \
    --cc=gdb-prs@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).