This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
Re: Patch: RFA PR libgcj/15430 (read keeps blocking after socketclosed).
- From: David Daney <ddaney at avtrex dot com>
- To: Java Patch List <java-patches at gcc dot gnu dot org>
- Date: Wed, 09 Nov 2005 16:30:25 -0800
- Subject: Re: Patch: RFA PR libgcj/15430 (read keeps blocking after socketclosed).
- References: <43724BE7.4000104@avtrex.com> <4372940A.10801@avtrex.com>
David Daney wrote:
+static void
+throw_on_sock_closed (gnu::java::net::PlainSocketImpl *soc_impl)
+{
+ // Avoid races from asynchronous close().
+ JvSynchronize sync (soc_impl);
+ if (soc_impl->native_fd == -1) {
+ // Socket was closed while blocked in recv.
This comment ^^^^^^ is a little misleading/incorrect. I will fix it if
approved.
David Daney.