Commit 7b522f79 authored by danil.martynenko's avatar danil.martynenko
Browse files

bugs-5076 | [*] fix set the current server

parent 51224c9e
......@@ -417,6 +417,14 @@ void ChChainNetSrvVpn::saveCurrentServer(const DapServerInfoList &nodelist)
}
}
void ChChainNetSrvVpn::saveCurrentServerFromAdress(const DapServerInfoList &nodelist, const QString &a_adress)
{
for(auto server : nodelist) {
if (server.address == a_adress && server.name != "Auto")
m_currentServer = server;
}
}
#ifdef ANDROID
extern "C" JNIEXPORT void JNICALL Java_com_KelVPN_KelVPNService_startWorker(JNIEnv *env, jobject instance, jint socket) {
......
......@@ -154,6 +154,7 @@ namespace Dap {
void tunStandby();
void saveCurrentServer(const DapServerInfoList &nodelist);
void saveCurrentServerFromAdress(const DapServerInfoList &nodelist, const QString &a_adress);
};
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment