Browse Source

removed Tor addresses

pull/5/head
orignal 7 years ago
parent
commit
df2cdb295a
  1. 18
      src/net.cpp
  2. 1
      src/net.h
  3. 5
      src/qt/bitcoingui.cpp
  4. 4
      src/qt/clientmodel.cpp

18
src/net.cpp

@ -23,7 +23,6 @@ @@ -23,7 +23,6 @@
#include <miniupnpc/upnperrors.h>
#endif
#define TOR_NET_STRING "tor"
// Dump addresses to peers.dat every 15 minutes (900s)
#define DUMP_ADDRESSES_INTERVAL 900
@ -129,22 +128,11 @@ bool IsDarknetOnly() @@ -129,22 +128,11 @@ bool IsDarknetOnly()
{
if (IsI2POnly())
return true;
if (IsTorOnly())
return true;
if (((mapArgs.count("-proxy") && mapArgs["-proxy"] != "0") || (mapArgs.count("-tor") &&
mapArgs["-tor"] != "0")) && (mapArgs.count("-i2p") && mapArgs["-i2p"] != "0"))
if ((mapArgs.count("-proxy") && mapArgs["-proxy"] != "0") && (mapArgs.count("-i2p") && mapArgs["-i2p"] != "0"))
return true;
return false;
}
bool IsTorOnly()
{
bool i2pOnly = false;
const std::vector<std::string>& onlyNets = mapMultiArgs["-onlynet"];
i2pOnly = (onlyNets.size() == 1 && onlyNets[0] == TOR_NET_STRING);
return i2pOnly;
}
bool IsI2POnly()
{
bool i2pOnly = false;
@ -172,12 +160,8 @@ bool IsBehindDarknet() @@ -172,12 +160,8 @@ bool IsBehindDarknet()
{
if (IsI2POnly())
return true;
if (IsTorOnly())
return true;
if (IsDarknetOnly())
return true;
if ((mapArgs.count("-tor") && mapArgs["-tor"] != "0"))
return true;
return false;
}

1
src/net.h

@ -50,7 +50,6 @@ bool BindListenNativeI2P(SOCKET& hSocket); @@ -50,7 +50,6 @@ bool BindListenNativeI2P(SOCKET& hSocket);
bool IsI2POnly();
bool IsI2PEnabled();
bool IsTorOnly();
bool IsDarknetOnly();
bool IsBehindDarknet();

5
src/qt/bitcoingui.cpp

@ -347,11 +347,6 @@ void BitcoinGUI::setClientModel(ClientModel *clientModel) @@ -347,11 +347,6 @@ void BitcoinGUI::setClientModel(ClientModel *clientModel)
labelI2POnly->setText("I2P");
labelI2POnly->setToolTip(tr("Wallet is using I2P-network only"));
}
else if (clientModel->isTorOnly())
{
labelI2POnly->setText("Tor");
labelI2POnly->setToolTip(tr("Wallet is using Tor-network only"));
}
else if (clientModel->isDarknetOnly())
{
labelI2POnly->setText("I&T");

4
src/qt/clientmodel.cpp

@ -149,10 +149,6 @@ bool ClientModel::isI2POnly() const @@ -149,10 +149,6 @@ bool ClientModel::isI2POnly() const
return IsI2POnly();
}
bool ClientModel::isTorOnly() const
{
return IsTorOnly();
}
bool ClientModel::isDarknetOnly() const
{

Loading…
Cancel
Save