I think threads shouldn't be able to do much during shutdown. For example I don't think they should suddenly open sockets. How about opening files? Or calling system()? Any ideas on a unified approach? Andrei