summaryrefslogtreecommitdiffstats
path: root/fs/open.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/open.c')
-rw-r--r--fs/open.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/open.c b/fs/open.c
index e9da4e32d..deb898f76 100644
--- a/fs/open.c
+++ b/fs/open.c
@@ -790,7 +790,7 @@ int filp_close(struct file *filp, fl_owner_t id)
int retval;
struct dentry *dentry = filp->f_dentry;
- if (filp->f_count == 0) {
+ if (!atomic_read(&filp->f_count)) {
printk("VFS: Close: file count is 0\n");
return 0;
}