upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main.cpp1
-rw-r--r--src/main.h1
-rw-r--r--src/main_gui.cpp3
-rw-r--r--src/nostr.cpp4
4 files changed, 7 insertions, 2 deletions
diff --git a/src/main.cpp b/src/main.cpp
index 32ab952..69d9d30 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -87,6 +87,7 @@ CKey keyUser;
87string strSetDataDir; 87string strSetDataDir;
88int nDropMessagesTest = 0; 88int nDropMessagesTest = 0;
89bool fSoloMineTest = false; // /solomine: mine without requiring a peer (local test) 89bool fSoloMineTest = false; // /solomine: mine without requiring a peer (local test)
90bool fPoolNoAnnounce = false; // /noannounce: operator serves miners but never publishes pool announcements
90 91
91// Settings 92// Settings
92int fGenerateBitcoins; 93int fGenerateBitcoins;
diff --git a/src/main.h b/src/main.h
index 307cee5..22be3dc 100644
--- a/src/main.h
+++ b/src/main.h
@@ -86,6 +86,7 @@ extern bool fMineModeFromCommandLine;
86extern string strParticipantPool; // participant: pool .btf address 86extern string strParticipantPool; // participant: pool .btf address
87extern string strPayoutAddress; // participant: /payoutaddr override (mine without a wallet) 87extern string strPayoutAddress; // participant: /payoutaddr override (mine without a wallet)
88extern string strPayoutFile; // participant: /payoutfile address list, rotated per reconnect 88extern string strPayoutFile; // participant: /payoutfile address list, rotated per reconnect
89extern bool fPoolNoAnnounce; // /noannounce: suppress pool announcements
89extern int nHashThreads; // participant: /hashthreads override (0 = cores-1) 90extern int nHashThreads; // participant: /hashthreads override (0 = cores-1)
90extern string strPoolName; // operator: announced pool name 91extern string strPoolName; // operator: announced pool name
91extern string strPoolDashboardUrl; // operator: optional dashboard URL 92extern string strPoolDashboardUrl; // operator: optional dashboard URL
diff --git a/src/main_gui.cpp b/src/main_gui.cpp
index d0969b5..b1fe0af 100644
--- a/src/main_gui.cpp
+++ b/src/main_gui.cpp
@@ -250,6 +250,9 @@ static void ParseStartupArguments(int argc, char* argv[])
250 if (!poolDash.empty()) 250 if (!poolDash.empty())
251 strPoolDashboardUrl = poolDash; 251 strPoolDashboardUrl = poolDash;
252 252
253 if (arg(argc,argv,"/noannounce") || arg(argc,argv,"-noannounce"))
254 fPoolNoAnnounce = true;
255
253 string poolFee = argval2(argc, argv, "/poolfee", "-poolfee"); 256 string poolFee = argval2(argc, argv, "/poolfee", "-poolfee");
254 if (!poolFee.empty()) 257 if (!poolFee.empty())
255 dPoolFeePercent = atof(poolFee.c_str()); 258 dPoolFeePercent = atof(poolFee.c_str());
diff --git a/src/nostr.cpp b/src/nostr.cpp
index 6d85bf6..47f001c 100644
--- a/src/nostr.cpp
+++ b/src/nostr.cpp
@@ -1405,7 +1405,7 @@ void ThreadBtfPoolAnnouncer(void*)
1405 LogPrint("pool", "ThreadBtfPoolAnnouncer started\n"); 1405 LogPrint("pool", "ThreadBtfPoolAnnouncer started\n");
1406 while (!fShutdown) 1406 while (!fShutdown)
1407 { 1407 {
1408 if (nMineMode == MINE_OPERATOR && gPoolRunning) 1408 if (nMineMode == MINE_OPERATOR && gPoolRunning && !fPoolNoAnnounce)
1409 { 1409 {
1410 BtfPoolAnnouncement ann; 1410 BtfPoolAnnouncement ann;
1411 ann.btfAddress = BtfLocalAddress(); 1411 ann.btfAddress = BtfLocalAddress();
@@ -1763,7 +1763,7 @@ void ThreadNostrSeed(void* parg)
1763 } 1763 }
1764 CATCH_PRINT_EXCEPTION("ConnectDiscoveredBtfPeers") 1764 CATCH_PRINT_EXCEPTION("ConnectDiscoveredBtfPeers")
1765 1765
1766 if (nMineMode == MINE_OPERATOR && gPoolRunning) 1766 if (nMineMode == MINE_OPERATOR && gPoolRunning && !fPoolNoAnnounce)
1767 { 1767 {
1768 BtfPoolAnnouncement ann; 1768 BtfPoolAnnouncement ann;
1769 ann.btfAddress = BtfLocalAddress(); 1769 ann.btfAddress = BtfLocalAddress();