Wait for logout