win32: Don't run cleanup if we're about to exit anyway
If the process is about to exit, there's no point trying to do
a bunch of work to clean up resources. The kernel will release
them much more efficiently when the process exits at the end
of this function.