diff options
author | David Woodhouse <dwmw2@infradead.org> | 2007-08-01 11:23:57 +0100 |
---|---|---|
committer | David Woodhouse <dwmw2@infradead.org> | 2007-08-01 11:23:57 +0100 |
commit | 440fdb53b4ae58602711b5b8c3a139ace2404dbb (patch) | |
tree | c6fb88d6ad537ec53aeecadc75a61ab6147d4c9c /fs/udf | |
parent | 8b2b403ce0f1a816b7a6a4f47c8798003b26c07a (diff) | |
parent | 8d4fbcfbe0a4bfc73e7f0297c59ae514e1f1436f (diff) |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
Diffstat (limited to 'fs/udf')
-rw-r--r-- | fs/udf/inode.c | 10 | ||||
-rw-r--r-- | fs/udf/super.c | 2 | ||||
-rw-r--r-- | fs/udf/udf_sb.h | 2 |
3 files changed, 10 insertions, 4 deletions
diff --git a/fs/udf/inode.c b/fs/udf/inode.c index 0d2c41666cd2..1652b2c665bb 100644 --- a/fs/udf/inode.c +++ b/fs/udf/inode.c @@ -1127,13 +1127,15 @@ static void udf_fill_inode(struct inode *inode, struct buffer_head *bh) } inode->i_uid = le32_to_cpu(fe->uid); - if (inode->i_uid == -1 || UDF_QUERY_FLAG(inode->i_sb, - UDF_FLAG_UID_IGNORE)) + if (inode->i_uid == -1 || + UDF_QUERY_FLAG(inode->i_sb, UDF_FLAG_UID_IGNORE) || + UDF_QUERY_FLAG(inode->i_sb, UDF_FLAG_UID_SET)) inode->i_uid = UDF_SB(inode->i_sb)->s_uid; inode->i_gid = le32_to_cpu(fe->gid); - if (inode->i_gid == -1 || UDF_QUERY_FLAG(inode->i_sb, - UDF_FLAG_GID_IGNORE)) + if (inode->i_gid == -1 || + UDF_QUERY_FLAG(inode->i_sb, UDF_FLAG_GID_IGNORE) || + UDF_QUERY_FLAG(inode->i_sb, UDF_FLAG_GID_SET)) inode->i_gid = UDF_SB(inode->i_sb)->s_gid; inode->i_nlink = le16_to_cpu(fe->fileLinkCount); diff --git a/fs/udf/super.c b/fs/udf/super.c index 7b30964665db..382be7be5ae3 100644 --- a/fs/udf/super.c +++ b/fs/udf/super.c @@ -366,11 +366,13 @@ static int udf_parse_options(char *options, struct udf_options *uopt) if (match_int(args, &option)) return 0; uopt->gid = option; + uopt->flags |= (1 << UDF_FLAG_GID_SET); break; case Opt_uid: if (match_int(args, &option)) return 0; uopt->uid = option; + uopt->flags |= (1 << UDF_FLAG_UID_SET); break; case Opt_umask: if (match_octal(args, &option)) diff --git a/fs/udf/udf_sb.h b/fs/udf/udf_sb.h index 3e937d3fb8f9..3c2982017c6d 100644 --- a/fs/udf/udf_sb.h +++ b/fs/udf/udf_sb.h @@ -24,6 +24,8 @@ #define UDF_FLAG_UID_IGNORE 12 /* use sb uid instead of on disk uid */ #define UDF_FLAG_GID_FORGET 13 #define UDF_FLAG_GID_IGNORE 14 +#define UDF_FLAG_UID_SET 15 +#define UDF_FLAG_GID_SET 16 #define UDF_PART_FLAG_UNALLOC_BITMAP 0x0001 #define UDF_PART_FLAG_UNALLOC_TABLE 0x0002 |