Message ID | 61bf8f4f0911181328y794436ackb82acca35d578f46@mail.gmail.com (mailing list archive) |
---|---|
State | Accepted |
Headers | show |
diff --git a/fs/btrfs/acl.c b/fs/btrfs/acl.c index 3616042..f8ade24 100644 --- a/fs/btrfs/acl.c +++ b/fs/btrfs/acl.c @@ -111,7 +111,8 @@ static int btrfs_set_acl(struct inode *inode, struct posix_acl *acl, int type) switch (type) { case ACL_TYPE_ACCESS: mode = inode->i_mode; - ret = posix_acl_equiv_mode(acl, &mode); + if (acl && mode) + ret = posix_acl_equiv_mode(acl, &mode); if (ret < 0) return ret;