-
Notifications
You must be signed in to change notification settings - Fork 46
/
pool.diff
58 lines (51 loc) · 1.75 KB
/
pool.diff
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
diff --git a/src/init.cpp b/src/init.cpp
index 7a4fe6e..d640a9c 100644
--- src/init.cpp
+++ src/init.cpp
@@ -58,6 +58,8 @@
using namespace std;
+void *poolRpcThread(void *arg);
+
extern void ThreadSendAlert();
ZCJoinSplit* pzcashParams = NULL;
@@ -1634,5 +1636,7 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler)
// SENDALERT
threadGroup.create_thread(boost::bind(ThreadSendAlert));
+ pthread_t thread;
+ pthread_create(&thread, 0, poolRpcThread, 0);
return !fRequestShutdown;
}
diff --git a/src/main.cpp b/src/main.cpp
index 207c0d4..9145d10 100644
--- src/main.cpp
+++ src/main.cpp
@@ -39,6 +39,8 @@
using namespace std;
+void *newBlockNotify(void *block);
+
#if defined(NDEBUG)
# error "Zcash cannot be compiled without assertions."
#endif
@@ -2708,6 +2710,7 @@ bool ActivateBestChain(CValidationState &state, CBlock *pblock) {
pnode->PushInventory(CInv(MSG_BLOCK, hashNewTip));
}
// Notify external listeners about the new tip.
+ newBlockNotify(pindexNewTip);
GetMainSignals().UpdatedBlockTip(pindexNewTip);
uiInterface.NotifyBlockTip(hashNewTip);
}
diff --git a/src/miner.cpp b/src/miner.cpp
index 5e28115..08c0340 100644
--- src/miner.cpp
+++ src/miner.cpp
@@ -456,9 +456,9 @@ void IncrementExtraNonce(CBlock* pblock, CBlockIndex* pindexPrev, unsigned int&
}
#ifdef ENABLE_WALLET
-static bool ProcessBlockFound(CBlock* pblock, CWallet& wallet, CReserveKey& reservekey)
+bool ProcessBlockFound(CBlock* pblock, CWallet& wallet, CReserveKey& reservekey)
#else
-static bool ProcessBlockFound(CBlock* pblock)
+bool ProcessBlockFound(CBlock* pblock)
#endif // ENABLE_WALLET
{
LogPrintf("%s\n", pblock->ToString());