Proposal: System.Timeout module for base (Trac #980)

Bayley, Alistair Alistair_Bayley at
Thu Mar 1 07:57:21 EST 2007

> This is a Windows-specific bug.  In fact all I/O on Windows 
> in the threaded RTS 
> is currently done with blocking foreign calls, so you won't 
> be able to kill any 
> threads blocked on I/O I'm afraid.  In the non-threaded RTS 
> you can kill the 
> Haskell thread, but the I/O will still happen (actually I 
> think this is worse 
> than the -threaded behaviour).

Damn my lame platform!

Well, that's a relief: at least I have an explanation as to why it works
that way. I was wondering how I would gracefully kill something waiting
for a socket accept.

I assume that when the process exits, all threads (OS or Haskell) are
terminated. So if I use the normal RTS, and have the main thread exit,
any thread waiting on a socket accept will be terminated too. That seems
to be my experience, anyway.

I'd offer to help but I'm no Windows expert, and 1-2 days effort would
be a few weeks elapsed time for me.

Confidentiality Note: The information contained in this message,
and any attachments, may contain confidential and/or privileged
material. It is intended solely for the person(s) or entity to
which it is addressed. Any review, retransmission, dissemination,
or taking of any action in reliance upon this information by
persons or entities other than the intended recipient(s) is
prohibited. If you received this in error, please contact the
sender and delete the material from any computer.

More information about the Libraries mailing list