Skip to content

Commit

Permalink
Changed incorrect Magic for testnet
Browse files Browse the repository at this point in the history
Reversed flags
  • Loading branch information
martin-key committed Oct 30, 2017
1 parent a40cbd0 commit d1579ea
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 18 deletions.
13 changes: 0 additions & 13 deletions src/chainparams.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -286,11 +286,6 @@ class CTestNetParams : public CChainParams {
// vSeeds.emplace_back("dnsseed.minepool.gold", true);
vSeeds.emplace_back("eu-test-dnsseed.bitcoingold-official.org", true);
vSeeds.emplace_back("btg.dnsseed.minertopia.org", true);
<<<<<<< HEAD
=======
vSeeds.emplace_back("testnet-seed.bitcoin.jonasschnelli.ch", true);
vSeeds.emplace_back("seed.tbtc.petertodd.org", true);
>>>>>>> Minor changes on the Magic

base58Prefixes[PUBKEY_ADDRESS] = std::vector<unsigned char>(1,111);
base58Prefixes[SCRIPT_ADDRESS] = std::vector<unsigned char>(1,196);
Expand Down Expand Up @@ -373,15 +368,7 @@ class CRegTestParams : public CChainParams {
pchMessageStart[1] = 0xbf;
pchMessageStart[2] = 0xb5;
pchMessageStart[3] = 0xda;
<<<<<<< HEAD

=======

pchMessageStart[0] = 0xde;
pchMessageStart[1] = 0xbf;
pchMessageStart[2] = 0xb5;
pchMessageStart[3] = 0xda;
>>>>>>> Minor changes on the Magic
nDefaultPort = 18444;
nPruneAfterHeight = 1000;
const size_t N = 48, K = 5;
Expand Down
2 changes: 1 addition & 1 deletion src/net.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2731,7 +2731,7 @@ CNode::CNode(NodeId idIn, ServiceFlags nLocalServicesIn, int nMyStartingHeightIn
nPingUsecStart = 0;
nPingUsecTime = 0;
fPingQueued = false;
fUsesGoldMagic = true;
fUsesGoldMagic = false;
nMinPingUsecTime = std::numeric_limits<int64_t>::max();
minFeeFilter = 0;
lastSentFeeFilter = 0;
Expand Down
4 changes: 0 additions & 4 deletions src/net.h
Original file line number Diff line number Diff line change
Expand Up @@ -697,11 +697,7 @@ class CNode
std::atomic<int64_t> nMinPingUsecTime;
// Whether a ping is requested.
std::atomic<bool> fPingQueued;
<<<<<<< HEAD
// Whether the node uses the bitcoin gold magic to communicate.
=======
// Whether the node uses the bitcoin cash magic to communicate.
>>>>>>> Legacy logic for Magic
std::atomic<bool> fUsesGoldMagic;

// Minimum fee rate with which to filter inv's to this node
Expand Down
4 changes: 4 additions & 0 deletions src/net_processing.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2732,11 +2732,15 @@ bool ProcessMessages(CNode* pfrom, CConnman& connman, const std::atomic<bool>& i
if (pfrom->nVersion == 0 &&
memcmp(msg.hdr.pchMessageStart, chainparams.MessageStart(),
CMessageHeader::MESSAGE_START_SIZE) == 0) {
<<<<<<< HEAD
<<<<<<< HEAD
pfrom->fUsesGoldMagic = true;
=======
pfrom->fUsesGoldMagic = false;
>>>>>>> Legacy logic for Magic
=======
pfrom->fUsesGoldMagic = true;
>>>>>>> Changed incorrect Magic for testnet
}

// Scan for message start
Expand Down

0 comments on commit d1579ea

Please sign in to comment.