From: Aaron Straus <aaron@merfinllc.com>
To: Michele Petrazzo <michele.petrazzo@unipex.it>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: [PATCH] start work on delete snapshot code
Date: Tue, 10 Feb 2009 12:27:52 -0800 [thread overview]
Message-ID: <20090210202752.GB20942@merfinllc.com> (raw)
In-Reply-To: <20090210195730.GA20942@merfinllc.com>
On Feb 10 11:57 AM, Aaron Straus wrote:
> Thanks for the traceback, I'll look into it tonight and try to figure
> out what went wrong.
Hi,
Actually that's an easy one. That's a bad way of saying file not
found i.e. you tried to delete a snapshot that wasn't there. Please
apply the following patch on top of the previous one.
Thanks!
=a=
--
===================
Aaron Straus
aaron@merfinllc.com
---
diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c
index 6e09873..496e8d6 100644
--- a/fs/btrfs/ioctl.c
+++ b/fs/btrfs/ioctl.c
@@ -787,6 +787,12 @@ static noinline int btrfs_ioctl_snap_destroy(struct file *file,
mutex_unlock(&dir->d_inode->i_mutex);
+ if (!inode) {
+ printk(KERN_INFO "btrfs: snapshot not found\n");
+ ret = -ENOENT;
+ goto out_dput;
+ }
+
/* (1) locks needed? */
if (!(inode->i_mode & S_IFDIR)) {
printk(KERN_INFO "btrfs: not directory\n");
prev parent reply other threads:[~2009-02-10 20:27 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-10 0:07 [PATCH] start work on delete snapshot code Aaron Straus
2009-02-10 1:09 ` Chris Mason
2009-02-10 1:42 ` Aaron Straus
2009-02-10 19:44 ` Michele Petrazzo
2009-02-10 19:57 ` Aaron Straus
2009-02-10 20:27 ` Aaron Straus [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=20090210202752.GB20942@merfinllc.com \
--to=aaron@merfinllc.com \
--cc=linux-btrfs@vger.kernel.org \
--cc=michele.petrazzo@unipex.it \
/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