projects
/
unionfs-2.6.25.y.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2da50dc
)
Unionfs: return EINVAL in setattr on error
author
Erez Zadok
<ezk@cs.sunysb.edu>
Fri, 19 Sep 2008 02:22:28 +0000
(22:22 -0400)
committer
Erez Zadok
<ezk@cs.sunysb.edu>
Mon, 12 Jan 2009 23:20:58 +0000
(18:20 -0500)
Signed-off-by: Erez Zadok <ezk@cs.sunysb.edu>
fs/unionfs/inode.c
patch
|
blob
|
history
diff --git
a/fs/unionfs/inode.c
b/fs/unionfs/inode.c
index a33171d55498ce0c2ce1cf04ee1a877c491f775f..36ceaafcfb470520f8950fe4e81cdb5db63846f8 100644
(file)
--- a/
fs/unionfs/inode.c
+++ b/
fs/unionfs/inode.c
@@
-914,7
+914,10
@@
static int unionfs_setattr(struct dentry *dentry, struct iattr *ia)
ia->ia_valid &= ~ATTR_MODE;
lower_dentry = unionfs_lower_dentry(dentry);
- BUG_ON(!lower_dentry); /* should never happen after above revalidate */
+ if (!lower_dentry) { /* should never happen after above revalidate */
+ err = -EINVAL;
+ goto out;
+ }
lower_inode = unionfs_lower_inode(inode);
/* check if user has permission to change lower inode */