diff --git a/[refs] b/[refs] index 189ea046bb9c..d7699a520f6d 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 72638f598ec9f05a43fcb22dc1dd8dc34c43acc1 +refs/heads/master: 4503efd0891c40e30928afb4b23dc3f99c62a6b2 diff --git a/trunk/fs/sysfs/bin.c b/trunk/fs/sysfs/bin.c index 66f6e58a7e4b..f2c478c3424e 100644 --- a/trunk/fs/sysfs/bin.c +++ b/trunk/fs/sysfs/bin.c @@ -63,6 +63,9 @@ read(struct file *file, char __user *userbuf, size_t bytes, loff_t *off) int count = min_t(size_t, bytes, PAGE_SIZE); char *temp; + if (!bytes) + return 0; + if (size) { if (offs > size) return 0; @@ -131,6 +134,9 @@ static ssize_t write(struct file *file, const char __user *userbuf, int count = min_t(size_t, bytes, PAGE_SIZE); char *temp; + if (!bytes) + return 0; + if (size) { if (offs > size) return 0;