From 0698a33dea5f8920617f2212697ee6438c80bf6d Mon Sep 17 00:00:00 2001 From: ed Date: Wed, 5 Aug 2015 07:36:50 +0000 Subject: Allow the creation of kqueues with a restricted set of Capsicum rights. On CloudABI we want to create file descriptors with just the minimal set of Capsicum rights in place. The reason for this is that it makes it easier to obtain uniform behaviour across different operating systems. By explicitly whitelisting the operations, we can return consistent error codes, but also prevent applications from depending OS-specific behaviour. Extend kern_kqueue() to take an additional struct filecaps that is passed on to falloc_caps(). Update the existing consumers to pass in NULL. Differential Revision: https://reviews.freebsd.org/D3259 --- sys/compat/linux/linux_event.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sys/compat') diff --git a/sys/compat/linux/linux_event.c b/sys/compat/linux/linux_event.c index fcb5753..b1ceadf 100644 --- a/sys/compat/linux/linux_event.c +++ b/sys/compat/linux/linux_event.c @@ -205,7 +205,7 @@ epoll_create_common(struct thread *td, int flags) { int error; - error = kern_kqueue(td, flags); + error = kern_kqueue(td, flags, NULL); if (error) return (error); -- cgit v1.1