svn commit: r314314 - head/sys/compat/linux

Dmitry Chagin dchagin at FreeBSD.org
Sun Feb 26 20:02:00 UTC 2017


Author: dchagin
Date: Sun Feb 26 20:01:58 2017
New Revision: 314314
URL: https://svnweb.freebsd.org/changeset/base/314314

Log:
  Return EINVAL in case when an invalid size of signal mask specified.
  
  MFC after:	1 month

Modified:
  head/sys/compat/linux/linux_event.c

Modified: head/sys/compat/linux/linux_event.c
==============================================================================
--- head/sys/compat/linux/linux_event.c	Sun Feb 26 19:59:28 2017	(r314313)
+++ head/sys/compat/linux/linux_event.c	Sun Feb 26 20:01:58 2017	(r314314)
@@ -622,6 +622,8 @@ linux_epoll_pwait(struct thread *td, str
 	int error;
 
 	if (args->mask != NULL) {
+		if (args->sigsetsize != sizeof(l_sigset_t))
+			return (EINVAL);
 		error = copyin(args->mask, &lmask, sizeof(l_sigset_t));
 		if (error != 0)
 			return (error);


More information about the svn-src-head mailing list