Fix a few problems when releaseFromQuarantine was called on the main thread.