aboutsummaryrefslogtreecommitdiff
path: root/src/net.h
diff options
context:
space:
mode:
authorMatt Corallo <git@bluematt.me>2012-08-13 05:26:29 +0200
committerMatt Corallo <git@bluematt.me>2013-01-16 12:48:02 -0500
commit422d1225374e2d879dbd116151e0113aa7162500 (patch)
tree4d468923fe3d01f5a348d677d214e5f9b1a222e4 /src/net.h
parent133a546074258862348177213bbe2200208affd8 (diff)
Add a filter field in CNode, add filterload+filteradd+filterclear
Diffstat (limited to 'src/net.h')
-rw-r--r--src/net.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/net.h b/src/net.h
index 44c80dac28..1ce92eae44 100644
--- a/src/net.h
+++ b/src/net.h
@@ -19,6 +19,7 @@
#include "protocol.h"
#include "addrman.h"
#include "hash.h"
+#include "bloom.h"
class CNode;
class CBlockIndex;
@@ -152,6 +153,8 @@ public:
bool fSuccessfullyConnected;
bool fDisconnect;
CSemaphoreGrant grantOutbound;
+ CCriticalSection cs_filter;
+ CBloomFilter* pfilter;
protected:
int nRefCount;
@@ -209,6 +212,7 @@ public:
fGetAddr = false;
nMisbehavior = 0;
setInventoryKnown.max_size(SendBufferSize() / 1000);
+ pfilter = NULL;
// Be shy and don't send version until we hear
if (!fInbound)
@@ -222,6 +226,8 @@ public:
closesocket(hSocket);
hSocket = INVALID_SOCKET;
}
+ if (pfilter)
+ delete pfilter;
}
private: