From owner-svn-src-all@FreeBSD.ORG Thu Jul 15 18:44:59 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5AFDB1065673; Thu, 15 Jul 2010 18:44:59 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 49E348FC0C; Thu, 15 Jul 2010 18:44:59 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o6FIixEu069733; Thu, 15 Jul 2010 18:44:59 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o6FIixDP069732; Thu, 15 Jul 2010 18:44:59 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201007151844.o6FIixDP069732@svn.freebsd.org> From: Edward Tomasz Napierala Date: Thu, 15 Jul 2010 18:44:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r210132 - head/sys/compat/svr4 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Jul 2010 18:44:59 -0000 Author: trasz Date: Thu Jul 15 18:44:58 2010 New Revision: 210132 URL: http://svn.freebsd.org/changeset/base/210132 Log: Make svr4(4) version of poll(2) use the same limit of file descriptors as the usual poll(2) does, instead of checking resource limits. Modified: head/sys/compat/svr4/svr4_filio.c Modified: head/sys/compat/svr4/svr4_filio.c ============================================================================== --- head/sys/compat/svr4/svr4_filio.c Thu Jul 15 17:49:35 2010 (r210131) +++ head/sys/compat/svr4/svr4_filio.c Thu Jul 15 18:44:58 2010 (r210132) @@ -40,8 +40,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#include -#include #include @@ -67,8 +65,7 @@ svr4_sys_poll(td, uap) u_long siz; PROC_LOCK(td->td_proc); - if (uap->nfds > lim_cur(td->td_proc, RLIMIT_NOFILE) && - uap->nfds > FD_SETSIZE) { + if (uap->nfds > maxfilesperproc && uap->nfds > FD_SETSIZE) { PROC_UNLOCK(td->td_proc); return (EINVAL); }