Skip to content

Commit

Permalink
Remove all other print() methods
Browse files Browse the repository at this point in the history
All unused.
  • Loading branch information
laanwj committed Aug 20, 2014
1 parent 9b6d4c5 commit 3802224
Show file tree
Hide file tree
Showing 10 changed files with 0 additions and 51 deletions.
5 changes: 0 additions & 5 deletions src/alert.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,11 +80,6 @@ std::string CUnsignedAlert::ToString() const
strStatusBar);
}

void CUnsignedAlert::print() const
{
LogPrintf("%s", ToString());
}

void CAlert::SetNull()
{
CUnsignedAlert::SetNull();
Expand Down
1 change: 0 additions & 1 deletion src/alert.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ class CUnsignedAlert
void SetNull();

std::string ToString() const;
void print() const;
};

/** An alert is a combination of a serialized CUnsignedAlert and a signature. */
Expand Down
1 change: 0 additions & 1 deletion src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3968,7 +3968,6 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv,
vRecv >> block;

LogPrint("net", "received block %s peer=%d\n", block.GetHash().ToString(), pfrom->id);
// block.print();

CInv inv(MSG_BLOCK, block.GetHash());
pfrom->AddInventoryKnown(inv);
Expand Down
10 changes: 0 additions & 10 deletions src/main.h
Original file line number Diff line number Diff line change
Expand Up @@ -839,11 +839,6 @@ class CBlockIndex
GetBlockHash().ToString());
}

void print() const
{
LogPrintf("%s\n", ToString());
}

// Check whether this block index entry is valid up to the passed validity level.
bool IsValid(enum BlockStatus nUpTo = BLOCK_VALID_TRANSACTIONS) const
{
Expand Down Expand Up @@ -935,11 +930,6 @@ class CDiskBlockIndex : public CBlockIndex
hashPrev.ToString());
return str;
}

void print() const
{
LogPrintf("%s\n", ToString());
}
};

/** Capture information about block/transaction validation */
Expand Down
8 changes: 0 additions & 8 deletions src/miner.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,6 @@ class COrphan
COrphan(const CTransaction* ptxIn) : ptx(ptxIn), feeRate(0), dPriority(0)
{
}

void print() const
{
LogPrintf("COrphan(hash=%s, dPriority=%.1f, fee=%s)\n",
ptx->GetHash().ToString(), dPriority, feeRate.ToString());
BOOST_FOREACH(uint256 hash, setDependsOn)
LogPrintf(" setDependsOn %s\n", hash.ToString());
}
};

uint64_t nLastBlockTx = 0;
Expand Down
10 changes: 0 additions & 10 deletions src/netbase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -874,11 +874,6 @@ uint64_t CNetAddr::GetHash() const
return nRet;
}

void CNetAddr::print() const
{
LogPrintf("CNetAddr(%s)\n", ToString());
}

// private extensions to enum Network, only returned by GetExtNetwork,
// and only used in GetReachabilityFrom
static const int NET_UNKNOWN = NET_MAX + 0;
Expand Down Expand Up @@ -1107,11 +1102,6 @@ std::string CService::ToString() const
return ToStringIPPort();
}

void CService::print() const
{
LogPrintf("CService(%s)\n", ToString());
}

void CService::SetPort(unsigned short portIn)
{
port = portIn;
Expand Down
2 changes: 0 additions & 2 deletions src/netbase.h
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,6 @@ class CNetAddr
bool GetInAddr(struct in_addr* pipv4Addr) const;
std::vector<unsigned char> GetGroup() const;
int GetReachabilityFrom(const CNetAddr *paddrPartner = NULL) const;
void print() const;

CNetAddr(const struct in6_addr& pipv6Addr);
bool GetIn6Addr(struct in6_addr* pipv6Addr) const;
Expand Down Expand Up @@ -145,7 +144,6 @@ class CService : public CNetAddr
std::string ToString() const;
std::string ToStringPort() const;
std::string ToStringIPPort() const;
void print() const;

CService(const struct in6_addr& ipv6Addr, unsigned short port);
CService(const struct sockaddr_in6& addr);
Expand Down
6 changes: 0 additions & 6 deletions src/protocol.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -144,9 +144,3 @@ std::string CInv::ToString() const
{
return strprintf("%s %s", GetCommand(), hash.ToString());
}

void CInv::print() const
{
LogPrintf("CInv(%s)\n", ToString());
}

3 changes: 0 additions & 3 deletions src/protocol.h
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,6 @@ class CAddress : public CService
READWRITE(*pip);
)

void print() const;

// TODO: make private (improves encapsulation)
public:
uint64_t nServices;
Expand Down Expand Up @@ -130,7 +128,6 @@ class CInv
bool IsKnownType() const;
const char* GetCommand() const;
std::string ToString() const;
void print() const;

// TODO: make private (improves encapsulation)
public:
Expand Down
5 changes: 0 additions & 5 deletions src/wallet.h
Original file line number Diff line number Diff line change
Expand Up @@ -824,11 +824,6 @@ class COutput
{
return strprintf("COutput(%s, %d, %d) [%s]", tx->GetHash().ToString(), i, nDepth, FormatMoney(tx->vout[i].nValue).c_str());
}

void print() const
{
LogPrintf("%s\n", ToString());
}
};


Expand Down

0 comments on commit 3802224

Please sign in to comment.