PATCH: fix return on pms change

From: Alan Cox (alan@lxorguk.ukuu.org.uk)
Date: Sun Jul 27 2003 - 15:05:52 EST


diff -u --new-file --recursive --exclude-from /usr/src/exclude linux-2.6.0-test2/drivers/media/video/pms.c linux-2.6.0-test2-ac1/drivers/media/video/pms.c
--- linux-2.6.0-test2/drivers/media/video/pms.c 2003-07-27 19:56:24.000000000 +0100
+++ linux-2.6.0-test2-ac1/drivers/media/video/pms.c 2003-07-27 20:17:24.000000000 +0100
@@ -664,7 +664,7 @@
                                 dt=count-len;
                         cnt += dev->height;
                         if (copy_to_user(buf, tmp+32, dt))
- return -EFAULT;
+ return len ? len : -EFAULT;
                         buf += dt;
                         len += dt;
                 }
-
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/



This archive was generated by hypermail 2b29 : Thu Jul 31 2003 - 22:00:33 EST