mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-02-10 22:04:13 +00:00
- Added some debug for proxy settings
This commit is contained in:
parent
5509e94778
commit
bc29577a7b
10
src/GUI.cpp
10
src/GUI.cpp
@ -1010,25 +1010,35 @@ void GUI::configureSession(bool deleteOptions) {
|
|||||||
if(options->isProxyEnabled()) {
|
if(options->isProxyEnabled()) {
|
||||||
qDebug("Enabling P2P proxy");
|
qDebug("Enabling P2P proxy");
|
||||||
proxySettings.hostname = options->getProxyIp().toStdString();
|
proxySettings.hostname = options->getProxyIp().toStdString();
|
||||||
|
qDebug("hostname is %s", proxySettings.hostname.c_str());
|
||||||
proxySettings.port = options->getProxyPort();
|
proxySettings.port = options->getProxyPort();
|
||||||
|
qDebug("port is %d", proxySettings.port);
|
||||||
if(options->isProxyAuthEnabled()) {
|
if(options->isProxyAuthEnabled()) {
|
||||||
|
|
||||||
proxySettings.username = options->getProxyUsername().toStdString();
|
proxySettings.username = options->getProxyUsername().toStdString();
|
||||||
proxySettings.password = options->getProxyPassword().toStdString();
|
proxySettings.password = options->getProxyPassword().toStdString();
|
||||||
|
qDebug("username is %s", proxySettings.username.c_str());
|
||||||
|
qDebug("password is %s", proxySettings.password.c_str());
|
||||||
}
|
}
|
||||||
switch(options->getProxyType()) {
|
switch(options->getProxyType()) {
|
||||||
case HTTP:
|
case HTTP:
|
||||||
|
qDebug("type: http");
|
||||||
proxySettings.type = proxy_settings::http;
|
proxySettings.type = proxy_settings::http;
|
||||||
break;
|
break;
|
||||||
case HTTP_PW:
|
case HTTP_PW:
|
||||||
|
qDebug("type: http_pw");
|
||||||
proxySettings.type = proxy_settings::http_pw;
|
proxySettings.type = proxy_settings::http_pw;
|
||||||
break;
|
break;
|
||||||
case SOCKS5:
|
case SOCKS5:
|
||||||
|
qDebug("type: socks5");
|
||||||
proxySettings.type = proxy_settings::socks5;
|
proxySettings.type = proxy_settings::socks5;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
qDebug("type: socks5_pw");
|
||||||
proxySettings.type = proxy_settings::socks5_pw;
|
proxySettings.type = proxy_settings::socks5_pw;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
qDebug("booleans: %d %d %d %d", options->useProxyForTrackers(), options->useProxyForPeers(), options->useProxyForWebseeds(), options->useProxyForDHT());
|
||||||
BTSession->setProxySettings(proxySettings, options->useProxyForTrackers(), options->useProxyForPeers(), options->useProxyForWebseeds(), options->useProxyForDHT());
|
BTSession->setProxySettings(proxySettings, options->useProxyForTrackers(), options->useProxyForPeers(), options->useProxyForWebseeds(), options->useProxyForDHT());
|
||||||
} else {
|
} else {
|
||||||
qDebug("Disabling P2P proxy");
|
qDebug("Disabling P2P proxy");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user