Unblocking blocked I/O

David Vrabel dv207@hermes.cam.ac.uk
Wed Sep 19 01:18:00 GMT 2001


Hi,

On Wed, 19 Sep 2001, Bryce McKinlay wrote:

> David Vrabel wrote:
>
> > [...]
> >I also tried Thread.interrupt() but that seemed completely broken.
> >
> This discussion has come up before. Last time, I think we agreed that
> the semantics of Thread.interrupt() were pretty much undefined when it
> comes to blocking I/O, and since its implementation varies significantly
> between platforms we wern't going to bother implementing it at all
> unless Sun fix it or clarify the spec.

Yeah.  I found that discussion.  So much for the claimed cross-platform
compatibility...

> Unblocking I/O by closing a socket (resource revocation), however,
> should work, and its a bug if it doesn't. Do you have a test case?

Yes.  It's perhaps a bit long but find it attached. Hmm.  Attachments are
okay aren't they?

David Vrabel


More information about the Java mailing list