diff --git a/clientgui/MainDocument.cpp b/clientgui/MainDocument.cpp index 79c6b5c8f8..7a89f45173 100644 --- a/clientgui/MainDocument.cpp +++ b/clientgui/MainDocument.cpp @@ -586,14 +586,15 @@ int CMainDocument::OnPoll() { pFrame->OnExit(event); // Exit if Select Computer dialog cancelled } } - if (wxGetApp().GetNeedRunDaemon()) { - if (m_pClientManager->StartupBOINCCore()) { - Connect(wxT("localhost"), portNum, password, TRUE, TRUE); - } - else { - m_pNetworkConnection->ForceDisconnect(); - pFrame->ShowDaemonStartFailedAlert(); - } + } + + if (wxGetApp().GetNeedRunDaemon() && IsComputerNameLocal(hostName)) { + if (m_pClientManager->StartupBOINCCore()) { + Connect(wxT("localhost"), portNum, password, TRUE, TRUE); + } + else { + m_pNetworkConnection->ForceDisconnect(); + pFrame->ShowDaemonStartFailedAlert(); } } else { Connect(hostName, portNum, password, TRUE, password.IsEmpty());