From owner-freebsd-hackers Mon Feb 14 14:44:25 2000 Delivered-To: freebsd-hackers@freebsd.org Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by builder.freebsd.org (Postfix) with ESMTP id 14BD14B44 for ; Mon, 14 Feb 2000 14:37:07 -0800 (PST) Received: from fledge.watson.org (robert@fledge.pr.watson.org [192.0.2.3]) by fledge.watson.org (8.9.3/8.9.3) with SMTP id RAA15645 for ; Mon, 14 Feb 2000 17:38:18 -0500 (EST) (envelope-from robert@cyrus.watson.org) Date: Mon, 14 Feb 2000 17:38:18 -0500 (EST) From: Robert Watson X-Sender: robert@fledge.watson.org Reply-To: Robert Watson To: freebsd-hackers@freebsd.org Subject: uthread: setsockopt while other threads blocked? Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG I'm using a threaded program to manage ipfw rules, and today discovered the hardware that you cannot simultaneously have a thread blocking on a recvfrom() on the raw socket to read icmp packets, and have another thread perform a setsockopt() to manipulate the ipfw rules. While it's easy to work around, opening a second raw socket, it seems like a bit of a wate, and results in more packet delivery to userland than necessary. Does the pthread spec address this? Would it be possible to set/getsockopt on a socket while it's in use? For example, retrieve peer information from a socket while a thread is blocked on reading the socket, or set buffering parameters? Thanks! Robert N M Watson robert@fledge.watson.org http://www.watson.org/~robert/ PGP key fingerprint: AF B5 5F FF A6 4A 79 37 ED 5F 55 E9 58 04 6A B1 TIS Labs at Network Associates, Safeport Network Services To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message