aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/main.cpp6
-rw-r--r--src/main.h8
2 files changed, 9 insertions, 5 deletions
diff --git a/src/main.cpp b/src/main.cpp
index f8f194afc5..5dcd378a77 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -618,7 +618,7 @@ int64 CTransaction::GetMinFee(unsigned int nBlockSize, bool fAllowFree,
else
{
// Free transaction area
- if (nNewBlockSize < 27000)
+ if (nNewBlockSize < DEFAULT_BLOCK_PRIORITY_SIZE)
nMinFee = 0;
}
}
@@ -4219,7 +4219,7 @@ CBlockTemplate* CreateNewBlock(CReserveKey& reservekey)
pblocktemplate->vTxSigOps.push_back(-1); // updated at end
// Largest block you're willing to create:
- unsigned int nBlockMaxSize = GetArg("-blockmaxsize", MAX_BLOCK_SIZE_GEN/2);
+ unsigned int nBlockMaxSize = GetArg("-blockmaxsize", DEFAULT_BLOCK_MAX_SIZE);
// Limit to betweeen 1K and MAX_BLOCK_SIZE-1K for sanity:
nBlockMaxSize = std::max((unsigned int)1000, std::min((unsigned int)(MAX_BLOCK_SIZE-1000), nBlockMaxSize));
@@ -4229,7 +4229,7 @@ CBlockTemplate* CreateNewBlock(CReserveKey& reservekey)
// How much of the block should be dedicated to high-priority transactions,
// included regardless of the fees they pay
- unsigned int nBlockPrioritySize = GetArg("-blockprioritysize", 27000);
+ unsigned int nBlockPrioritySize = GetArg("-blockprioritysize", DEFAULT_BLOCK_PRIORITY_SIZE);
nBlockPrioritySize = std::min(nBlockMaxSize, nBlockPrioritySize);
// Minimum block size you want to create; block will be filled with free transactions
diff --git a/src/main.h b/src/main.h
index 94260dc2e4..2fc683cd6d 100644
--- a/src/main.h
+++ b/src/main.h
@@ -26,10 +26,14 @@ struct CBlockIndexWorkComparator;
/** The maximum allowed size for a serialized block, in bytes (network rule) */
static const unsigned int MAX_BLOCK_SIZE = 1000000;
-/** The maximum size for mined blocks */
+/** Obsolete: maximum size for mined blocks */
static const unsigned int MAX_BLOCK_SIZE_GEN = MAX_BLOCK_SIZE/2;
+/** Default for -blockmaxsize, maximum size for mined blocks **/
+static const unsigned int DEFAULT_BLOCK_MAX_SIZE = 300000;
+/** Default for -blockprioritysize, maximum space for zero/low-fee transactions **/
+static const unsigned int DEFAULT_BLOCK_PRIORITY_SIZE = 30000;
/** The maximum size for transactions we're willing to relay/mine */
-static const unsigned int MAX_STANDARD_TX_SIZE = MAX_BLOCK_SIZE_GEN/5;
+static const unsigned int MAX_STANDARD_TX_SIZE = 100000;
/** The maximum allowed number of signature check operations in a block (network rule) */
static const unsigned int MAX_BLOCK_SIGOPS = MAX_BLOCK_SIZE/50;
/** The maximum number of orphan transactions kept in memory */