mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-18 02:46:06 +00:00
ima: Use inode_is_open_for_write
Use the aptly named function rather than open coding the check. No functional changes. Signed-off-by: Nikolay Borisov <nborisov@suse.com> Signed-off-by: Mimi Zohar <zohar@linux.ibm.com>
This commit is contained in:
parent
d7cecb676d
commit
eed9de3b4f
@ -103,7 +103,7 @@ static void ima_rdwr_violation_check(struct file *file,
|
|||||||
} else {
|
} else {
|
||||||
if (must_measure)
|
if (must_measure)
|
||||||
set_bit(IMA_MUST_MEASURE, &iint->atomic_flags);
|
set_bit(IMA_MUST_MEASURE, &iint->atomic_flags);
|
||||||
if ((atomic_read(&inode->i_writecount) > 0) && must_measure)
|
if (inode_is_open_for_write(inode) && must_measure)
|
||||||
send_writers = true;
|
send_writers = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user