summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2016-09-23 09:45:15 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2016-09-23 09:45:15 -0700
commite47f2e50ead9dd9eb10b2626d739760e71ce6d43 (patch)
treef841a01ac6f5b9a41ba33589ef1358a9f95dd954
parentb1f2beb87bb034bb209773807994279f90cace78 (diff)
parent42857cf512cb34c2c8cb50f1e766689d979d64e0 (diff)
downloadlinux-e47f2e50ead9dd9eb10b2626d739760e71ce6d43.tar.bz2
Merge tag 'configfs-for-4.8-2' of git://git.infradead.org/users/hch/configfs
Pull configfs fix from Christoph Hellwig: "One more trivial fix for the binary attribute code from Phil Turnbull" * tag 'configfs-for-4.8-2' of git://git.infradead.org/users/hch/configfs: configfs: Return -EFBIG from configfs_write_bin_file.
-rw-r--r--fs/configfs/file.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/configfs/file.c b/fs/configfs/file.c
index c30cf49b69d2..2c6312db8516 100644
--- a/fs/configfs/file.c
+++ b/fs/configfs/file.c
@@ -333,6 +333,7 @@ configfs_write_bin_file(struct file *file, const char __user *buf,
if (bin_attr->cb_max_size &&
*ppos + count > bin_attr->cb_max_size) {
len = -EFBIG;
+ goto out;
}
tbuf = vmalloc(*ppos + count);