From owner-freebsd-audit Mon Jul 23 23:30: 0 2001 Delivered-To: freebsd-audit@freebsd.org Received: from scientia.demon.co.uk (scientia.demon.co.uk [212.228.14.13]) by hub.freebsd.org (Postfix) with ESMTP id A896237B405 for ; Mon, 23 Jul 2001 23:29:55 -0700 (PDT) (envelope-from ben@FreeBSD.org) Received: from strontium.shef.vinosystems.com ([192.168.91.36] ident=root) by scientia.demon.co.uk with esmtp (Exim 3.30 #1) id 15OvhZ-000Hvl-00; Tue, 24 Jul 2001 07:29:53 +0100 Received: (from ben@localhost) by strontium.shef.vinosystems.com (8.11.4/8.11.4) id f6O6Trv94792; Tue, 24 Jul 2001 07:29:53 +0100 (BST) (envelope-from ben@FreeBSD.org) X-Authentication-Warning: strontium.shef.vinosystems.com: ben set sender to ben@FreeBSD.org using -f Date: Tue, 24 Jul 2001 07:29:53 +0100 From: Ben Smithurst To: Kris Kennaway Cc: audit@FreeBSD.org Subject: Re: rwhod signal fixes Message-ID: <20010724072952.A14233@strontium.shef.vinosystems.com> References: <20010723223904.A1381@xor.obsecurity.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-md5; protocol="application/pgp-signature"; boundary="Qxx1br4bt0+wmkIi" Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010723223904.A1381@xor.obsecurity.org> X-PGP-Key: http://www.smithurst.org/ben/pgp-key.txt Sender: owner-freebsd-audit@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --Qxx1br4bt0+wmkIi Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Kris Kennaway wrote: > + n =3D poll(pfd, 1, 1000); Is it really necessary to have rwhod go round in a loop like this wasting CPU time? What was wrong with using alarm() ? It doesn't seem to work either -- it doesn't see any of the broadcast messages, while the old rwhod works just fine. =2E.. Ah, I see the problem, that pfd[0].revents =3D POLLIN line should be pfd[0].revents =3D pfd[0].events =3D POLLIN, I think. After making that change it works, but I still don't see why it has to sit in a loop waking up every second to do bugger all. --=20 Ben Smithurst / ben@FreeBSD.org FreeBSD: The Power To Serve http://www.FreeBSD.org/ --Qxx1br4bt0+wmkIi Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (FreeBSD) Comment: For info see http://www.gnupg.org iD8DBQE7XRXgbPzJ+yzvRCwRAmlVAKCMKfo+TzvZEheqsFU1htQCl7F1uwCferrI eeA3JVhEnHhnS2KUJTWpMZ8= =859f -----END PGP SIGNATURE----- --Qxx1br4bt0+wmkIi-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-audit" in the body of the message