Subject: Re: CVS commit: src/lib/libc/rpc
To: Chuck Silvers <chuq@chuq.com>
From: Rui Paulo <rpaulo@fnop.net>
List: source-changes
Date: 11/05/2005 22:26:38
--PNTmBPCT7hxwcZjr
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
On 2005.11.05 08:08:12 -0800, Chuck Silvers wrote:
| hi,
|=20
| this change re-introduces the bug that the previous change fixed,
| namely that signals do not interrupt the syscall that's waiting
| for a packet to arrive or the timeout to expire. for this to work,
| it would need to add all previously-unmasked signals to the kqueue
| event list (since there doesn't appear to be a way to ask for
| multiple signals as one event).
I see the problem.
| since there's only 1 file descriptor in this case, it seems better
| to just go back to the previous pollts() implementation.
The objective here was, as the FreeBSD commit log shows:
Revision 1.15 / (download) - annotate - [select for diffs], Tue Oct 15
22:28:59 2002 UTC (3 years ago) by iedowse
Branch: MAIN
CVS Tags: RELENG_5_1_BP, RELENG_5_1_0_RELEASE, RELENG_5_1,
RELENG_5_0_BP, RELENG_5_0_0_RELEASE, RELENG_5_0
Changes since 1.14: +90 -158 lines
Use kqueue(2) instead of poll(2) to wait for replies and timeouts
in the UDP RPC client code. As a side-effect, this fixes some bugs
that might prevent the RPC call from ever timing out for example
if the server keeps responding with the wrong xid. This could
probably be simplified further by using the EVFILT_TIMER filter.
| separately, shouldn't pollts() have replacement version in libpthread
| so that changes to the signal mask only affect the current thread's
| mask instead of the process-global mask?
Good point. I think it should.
-- Rui Paulo
--PNTmBPCT7hxwcZjr
Content-Type: application/pgp-signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (NetBSD)
iD8DBQFDbTGeZPqyxs9FH4QRAp7aAJ0Y/Q+aBna/FXw39C/Zj/XdjkkC6QCfRCZF
SRRAl1BhdHF82k/dHzqGo7w=
=2c1Y
-----END PGP SIGNATURE-----
--PNTmBPCT7hxwcZjr--