Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 263738
b: refs/heads/master
c: 4815053
h: refs/heads/master
v: v3
  • Loading branch information
David Sterba authored and Chris Mason committed Sep 11, 2011
1 parent 612f927 commit 249369d
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a39f75214358d715efa21e2bccf5a709d8649144
refs/heads/master: 4815053aba7f2304055745df820cd74a39fdaab2
9 changes: 9 additions & 0 deletions trunk/fs/btrfs/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,12 @@ static int do_setxattr(struct btrfs_trans_handle *trans,
if (ret)
goto out;
btrfs_release_path(path);

/*
* remove the attribute
*/
if (!value)
goto out;
}

again:
Expand Down Expand Up @@ -158,6 +164,9 @@ static int do_setxattr(struct btrfs_trans_handle *trans,
return ret;
}

/*
* @value: "" makes the attribute to empty, NULL removes it
*/
int __btrfs_setxattr(struct btrfs_trans_handle *trans,
struct inode *inode, const char *name,
const void *value, size_t size, int flags)
Expand Down

0 comments on commit 249369d

Please sign in to comment.