Auth/Main: Fix crashes on shutdown

"mutex destroyed while busy"