All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] fs/btrfs: Return EPERM for rmdir on subvolumes and snapshots
@ 2010-04-08 20:35 Harshavardhana
  2010-04-08 22:07 ` David Brown
  0 siblings, 1 reply; 3+ messages in thread
From: Harshavardhana @ 2010-04-08 20:35 UTC (permalink / raw)
  To: linux-btrfs

rmdir on subvolumes and snapshots should return "EPERM"
rather than ENOTEMPTY. Just to be more descriptive. 

Signed-off-by: Harshavardhana <harsha@gluster.com>
---
 fs/btrfs/inode.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c
index a85b90c..c0fbe03 100644
--- a/fs/btrfs/inode.c
+++ b/fs/btrfs/inode.c
@@ -2593,7 +2593,7 @@ static int btrfs_rmdir(struct inode *dir, struct dentry *dentry)
 
 	if (inode->i_size > BTRFS_EMPTY_DIR_SIZE ||
 	    inode->i_ino == BTRFS_FIRST_FREE_OBJECTID)
-		return -ENOTEMPTY;
+		return -EPERM;
 
 	ret = btrfs_reserve_metadata_space(root, 5);
 	if (ret)
-- 
1.6.6.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-04-08 22:35 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-04-08 20:35 [PATCH] fs/btrfs: Return EPERM for rmdir on subvolumes and snapshots Harshavardhana
2010-04-08 22:07 ` David Brown
2010-04-08 22:35   ` Harshavardhana

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.