fix fadvise64() return type

David Mosberger (davidm@napali.hpl.hp.com)
Tue, 11 Feb 2003 14:40:59 -0800


Please remember to declare the return-type of syscall stubs as "long".
On 64-bit platforms, it's generally necessary to ensure that the
entire 64-bit return value is valid (and can be checked against
negative values).

Thanks,

--david

===== mm/fadvise.c 1.1 vs edited =====
--- 1.1/mm/fadvise.c Mon Feb 3 23:46:36 2003
+++ edited/mm/fadvise.c Tue Feb 11 14:38:21 2003
@@ -20,7 +20,7 @@
* POSIX_FADV_WILLNEED could set PG_Referenced, and POSIX_FADV_NOREUSE could
* deactivate the pages and clear PG_Referenced.
*/
-int sys_fadvise64(int fd, loff_t offset, size_t len, int advice)
+long sys_fadvise64(int fd, loff_t offset, size_t len, int advice)
{
struct file *file = fget(fd);
struct inode *inode;
-
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/