diff options
author | Wei Yuan <weiyuan.wei@huawei.com> | 2015-04-02 23:50:48 -0400 |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2015-04-02 23:50:48 -0400 |
commit | 5f80f62adae2a2920781a847805d34b36b323f7d (patch) | |
tree | 189f8946245e27436587f268f0c964e10467b97d /fs/ext4 | |
parent | 72b8e0f9fa8aee7e623808af1a5f33b70ebcb2c7 (diff) |
ext4: remove useless condition in if statement.
In this if statement, the previous condition is useless, the later one
has covered it.
Signed-off-by: Weiyuan <weiyuan.wei@huawei.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Reviewed-by: Lukas Czerner <lczerner@redhat.com>
Diffstat (limited to 'fs/ext4')
-rw-r--r-- | fs/ext4/xattr.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/ext4/xattr.c b/fs/ext4/xattr.c index 99a2cf858c8f..759842ff8af0 100644 --- a/fs/ext4/xattr.c +++ b/fs/ext4/xattr.c | |||
@@ -638,8 +638,7 @@ ext4_xattr_set_entry(struct ext4_xattr_info *i, struct ext4_xattr_search *s) | |||
638 | free += EXT4_XATTR_LEN(name_len); | 638 | free += EXT4_XATTR_LEN(name_len); |
639 | } | 639 | } |
640 | if (i->value) { | 640 | if (i->value) { |
641 | if (free < EXT4_XATTR_SIZE(i->value_len) || | 641 | if (free < EXT4_XATTR_LEN(name_len) + |
642 | free < EXT4_XATTR_LEN(name_len) + | ||
643 | EXT4_XATTR_SIZE(i->value_len)) | 642 | EXT4_XATTR_SIZE(i->value_len)) |
644 | return -ENOSPC; | 643 | return -ENOSPC; |
645 | } | 644 | } |