[patch] epoll - fix size check in epoll_create

From: Davide Libenzi
Date: Tue May 12 2009 - 15:15:42 EST


Andrew, this one-liner fixes a size check WRT the manual pages, that had
been broken somewhere in the past (might have been Uli with the
open-with-flags changes, though I'm not sure).



Signed-off-by: Davide Libenzi <davidel@xxxxxxxxxxxxxxx>


- Davide


---
fs/eventpoll.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

Index: linux-2.6.mod/fs/eventpoll.c
===================================================================
--- linux-2.6.mod.orig/fs/eventpoll.c 2009-05-12 12:05:36.000000000 -0700
+++ linux-2.6.mod/fs/eventpoll.c 2009-05-12 12:05:56.000000000 -0700
@@ -1212,7 +1212,7 @@ SYSCALL_DEFINE1(epoll_create1, int, flag

SYSCALL_DEFINE1(epoll_create, int, size)
{
- if (size < 0)
+ if (size <= 0)
return -EINVAL;

return sys_epoll_create1(0);

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/