From: David Sterba <dsterba@suse.cz>
To: "Dāvis Mosāns" <davispuh@gmail.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: [PATCH] btrfs-progs: process_snapshot: don't free ERR
Date: Mon, 3 Jan 2022 15:56:33 +0100 [thread overview]
Message-ID: <20220103145633.GI28560@twin.jikos.cz> (raw)
In-Reply-To: <20220102015016.48470-1-davispuh@gmail.com>
On Sun, Jan 02, 2022 at 03:50:16AM +0200, Dāvis Mosāns wrote:
> When some error happens when trying to search for parent subvolume
> then parent_subvol will contain errno so don't try to free that
>
> Crash backtrace would look like:
> 0 process_snapshot at cmds/receive.c:358
> 358 free(parent_subvol->path);
> 1 0x00005646898aaa67 in read_and_process_cmd at common/send-stream.c:348
> 2 btrfs_read_and_process_send_stream at common/send-stream.c:525
> 3 0x00005646898c9b8b in do_receive at cmds/receive.c:1113
> 4 cmd_receive at cmds/receive.c:1316
> 5 0x00005646898750b1 in cmd_execute at cmds/commands.h:125
> 6 main at btrfs.c:405
>
> (gdb) p parent_subvol
> $1 = (struct subvol_info *) 0xfffffffffffffffe
>
> Signed-off-by: Dāvis Mosāns <davispuh@gmail.com>
Added to devel, thanks.
prev parent reply other threads:[~2022-01-03 14:57 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-02 1:50 [PATCH] btrfs-progs: process_snapshot: don't free ERR Dāvis Mosāns
2022-01-02 4:45 ` Qu Wenruo
2022-01-03 14:56 ` David Sterba [this message]
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=20220103145633.GI28560@twin.jikos.cz \
--to=dsterba@suse.cz \
--cc=davispuh@gmail.com \
--cc=linux-btrfs@vger.kernel.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