make safeShutdown() asynchronous as it should always have been
1.6.12