fix: remove scheme for windows

since it will break some application that get proxy information from system
This commit is contained in:
ymshenyu 2020-04-30 13:31:42 +08:00
parent 8be0eb14d5
commit f237e623cf

View File

@ -212,7 +212,8 @@ namespace Qv2ray::components::proxy
}
#ifdef Q_OS_WIN
QString __a = (hasHTTP ? "http://" : "socks5://") + address + ":" + QSTRN(hasHTTP ? httpPort : socksPort);
const auto scheme = (hasHTTP ? "" : "socks5://");
QString __a = scheme + address + ":" + QSTRN(hasHTTP ? httpPort : socksPort);
LOG(MODULE_PROXY, "Windows proxy string: " + __a)
auto proxyStrW = new WCHAR[__a.length() + 1];