aboutsummaryrefslogtreecommitdiff
path: root/src/main.cpp
diff options
context:
space:
mode:
authorJeff Garzik <jgarzik@exmulti.com>2012-06-23 21:38:33 -0400
committerJeff Garzik <jgarzik@redhat.com>2012-06-23 21:38:33 -0400
commit983e4bdef00534d8d5277617f4d84fc326834957 (patch)
tree74bfaf75c66d9cc805c564ca1940a84244b89895 /src/main.cpp
parentd62a1947be5350ed60066ccacc7aba43bbdf48fb (diff)
downloadbitcoin-983e4bdef00534d8d5277617f4d84fc326834957.tar.xz
Quieten 'getdata' P2P message output
Output one message per getdata, not one message per 'inv' entry.
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/main.cpp b/src/main.cpp
index a49d2a06b4..3f5848a85c 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -2575,11 +2575,15 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv)
return error("message getdata size() = %d", vInv.size());
}
+ if (fDebugNet || (vInv.size() != 1))
+ printf("received getdata (%d invsz)\n", vInv.size());
+
BOOST_FOREACH(const CInv& inv, vInv)
{
if (fShutdown)
return true;
- printf("received getdata for: %s\n", inv.ToString().c_str());
+ if (fDebugNet || (vInv.size() == 1))
+ printf("received getdata for: %s\n", inv.ToString().c_str());
if (inv.type == MSG_BLOCK)
{