diff options
author | Artem Bityutskiy <Artem.Bityutskiy@nokia.com> | 2011-05-26 02:43:34 -0400 |
---|---|---|
committer | Artem Bityutskiy <dedekind1@gmail.com> | 2011-07-04 03:54:26 -0400 |
commit | a29fa9dfa4d5d1b962825c79f19d9b6f3f15843b (patch) | |
tree | bd7aa3733a869c69038b4474229fbc9ada002cbf /fs/ubifs/super.c | |
parent | 1b51e98365e42c27eb2664f8353bc62ab8c55c85 (diff) |
UBIFS: minor cleanup: use S_ISREG helper
Instead of using long "(inode->i_mode & S_IFMT) != S_IFREG" expression, use
shorted "!S_ISREG(inode->i_mode)".
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Diffstat (limited to 'fs/ubifs/super.c')
-rw-r--r-- | fs/ubifs/super.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ubifs/super.c b/fs/ubifs/super.c index de82c5d04ab9..285038548da9 100644 --- a/fs/ubifs/super.c +++ b/fs/ubifs/super.c | |||
@@ -85,7 +85,7 @@ static int validate_inode(struct ubifs_info *c, const struct inode *inode) | |||
85 | if (ui->data_len < 0 || ui->data_len > UBIFS_MAX_INO_DATA) | 85 | if (ui->data_len < 0 || ui->data_len > UBIFS_MAX_INO_DATA) |
86 | return 4; | 86 | return 4; |
87 | 87 | ||
88 | if (ui->xattr && (inode->i_mode & S_IFMT) != S_IFREG) | 88 | if (ui->xattr && !S_ISREG(inode->i_mode)) |
89 | return 5; | 89 | return 5; |
90 | 90 | ||
91 | if (!ubifs_compr_present(ui->compr_type)) { | 91 | if (!ubifs_compr_present(ui->compr_type)) { |