All of lore.kernel.org
 help / color / mirror / Atom feed
From: Josef Bacik <josef@toxicpanda.com>
To: Dan Carpenter <dan.carpenter@oracle.com>
Cc: Chris Mason <clm@fb.com>, David Sterba <dsterba@suse.com>,
	Anand Jain <anand.jain@oracle.com>,
	linux-btrfs@vger.kernel.org, kernel-janitors@vger.kernel.org
Subject: Re: [PATCH] btrfs: fix error pointer dereference in btrfs_ioctl_rm_dev_v2()
Date: Tue, 16 Nov 2021 09:39:06 -0500	[thread overview]
Message-ID: <YZPCii3nsASV6Ofz@localhost.localdomain> (raw)
In-Reply-To: <20211116115025.GC11936@kili>

On Tue, Nov 16, 2021 at 02:50:25PM +0300, Dan Carpenter wrote:
> If memdup_user() fails the error handing will crash when it tries
> to kfree() an error pointer.  Just return directly because there is
> no cleanup required.
> 
> Fixes: 1a15eb724aae ("btrfs: use btrfs_get_dev_args_from_path in dev removal ioctls")
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

Reviewed-by: Josef Bacik <josef@toxicpanda.com>

Thanks,

Josef

  reply	other threads:[~2021-11-16 14:39 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-16 11:50 [PATCH] btrfs: fix error pointer dereference in btrfs_ioctl_rm_dev_v2() Dan Carpenter
2021-11-16 14:39 ` Josef Bacik [this message]
2021-11-16 16:19 ` David Sterba

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=YZPCii3nsASV6Ofz@localhost.localdomain \
    --to=josef@toxicpanda.com \
    --cc=anand.jain@oracle.com \
    --cc=clm@fb.com \
    --cc=dan.carpenter@oracle.com \
    --cc=dsterba@suse.com \
    --cc=kernel-janitors@vger.kernel.org \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.