From owner-cvs-lib Sun Sep 14 17:36:42 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id RAA14778 for cvs-lib-outgoing; Sun, 14 Sep 1997 17:36:42 -0700 (PDT) Received: from precipice.shockwave.com (precipice.shockwave.com [207.105.15.229]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id RAA14694; Sun, 14 Sep 1997 17:35:18 -0700 (PDT) Received: from shockwave.com (localhost [127.0.0.1]) by precipice.shockwave.com (8.8.6/8.7.3) with ESMTP id RAA12560; Sun, 14 Sep 1997 17:32:28 -0700 (PDT) Message-Id: <199709150032.RAA12560@precipice.shockwave.com> To: Peter Wemm cc: cvs-committers@FreeBSD.ORG, cvs-all@FreeBSD.ORG, cvs-lib@FreeBSD.ORG Subject: Re: cvs commit: src/lib/libc/net res_send.c In-reply-to: Your message of "Sun, 14 Sep 1997 02:44:35 PDT." <199709140944.CAA18300@freefall.freebsd.org> Date: Sun, 14 Sep 1997 17:32:28 -0700 From: Paul Traina Sender: owner-cvs-lib@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk Thanks, this was a good thing to do (tm). Overkill away. :-) From: Peter Wemm Subject: cvs commit: src/lib/libc/net res_send.c peter 1997/09/14 02:44:35 PDT Modified files: lib/libc/net res_send.c Log: Call poll(2) from within the resolver but adapt to older kernels without it if necessary. This removes the need to malloc large fd_set's for selecting on high fd's (larger than FD_SETSIZE at libc compile time). The syscall adaptive stuff only happens on the very first call. SIGSYS is masked, and if the call to poll fails with ENOSYS, then we use select for the life of the program. If poll does not fail with ENOSYS, then we always use poll and skip the once-off signal masking gunk. This may be overkill, but it saved my neck a few times while working on multiple different sets of kernel sources, some with poll, some without. Revision Changes Path 1.19 +68 -26 src/lib/libc/net/res_send.c