aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCory Fields <[email protected]>2013-05-26 14:00:16 -0400
committerCory Fields <[email protected]>2013-06-04 03:54:14 -0400
commit13c84b3bd550f93bf6c2bf57677a08a1ea858c60 (patch)
tree5c9b91ad4cf68647d933ff9936a273d4c93ab8cd /src
parentbuild: split the non-gui startup routines into a new file (diff)
downloaddiscoin-13c84b3bd550f93bf6c2bf57677a08a1ea858c60.tar.xz
discoin-13c84b3bd550f93bf6c2bf57677a08a1ea858c60.zip
build: add global var for whether or not the gui is enabled
Diffstat (limited to 'src')
-rw-r--r--src/bitcoind.cpp1
-rw-r--r--src/main.cpp1
-rw-r--r--src/main.h1
-rw-r--r--src/qt/bitcoin.cpp2
4 files changed, 5 insertions, 0 deletions
diff --git a/src/bitcoind.cpp b/src/bitcoind.cpp
index 81f67802d..682a214fb 100644
--- a/src/bitcoind.cpp
+++ b/src/bitcoind.cpp
@@ -123,6 +123,7 @@ extern void noui_connect();
int main(int argc, char* argv[])
{
bool fRet = false;
+ fHaveGUI = false;
// Connect bitcoind signal handlers
noui_connect();
diff --git a/src/main.cpp b/src/main.cpp
index a98b83b6a..b8b777161 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -48,6 +48,7 @@ bool fReindex = false;
bool fBenchmark = false;
bool fTxIndex = false;
unsigned int nCoinCacheSize = 5000;
+bool fHaveGUI = false;
/** Fees smaller than this (in satoshi) are considered zero fee (for transaction creation) */
int64 CTransaction::nMinTxFee = 10000; // Override with -mintxfee
diff --git a/src/main.h b/src/main.h
index 679ae75a4..fae37ea51 100644
--- a/src/main.h
+++ b/src/main.h
@@ -94,6 +94,7 @@ extern bool fBenchmark;
extern int nScriptCheckThreads;
extern bool fTxIndex;
extern unsigned int nCoinCacheSize;
+extern bool fHaveGUI;
// Settings
extern int64 nTransactionFee;
diff --git a/src/qt/bitcoin.cpp b/src/qt/bitcoin.cpp
index 73a5a12ef..76e88b36a 100644
--- a/src/qt/bitcoin.cpp
+++ b/src/qt/bitcoin.cpp
@@ -113,6 +113,8 @@ static void handleRunawayException(std::exception *e)
#ifndef BITCOIN_QT_TEST
int main(int argc, char *argv[])
{
+ fHaveGUI = true;
+
// Command-line options take precedence:
ParseParameters(argc, argv);