Hugh
--- linux-2.4.8-pre1/drivers/char/mem.c Wed Jul 11 00:07:46 2001
+++ linux/drivers/char/mem.c Fri Jul 27 21:40:05 2001
@@ -260,7 +260,9 @@
if (len > PAGE_SIZE)
len = PAGE_SIZE;
len = vread(kbuf, (char *)p, len);
- if (len && copy_to_user(buf, kbuf, len)) {
+ if (!len)
+ break;
+ if (copy_to_user(buf, kbuf, len)) {
free_page((unsigned long)kbuf);
return -EFAULT;
}
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/