Hi I'm trying to understand the default behavior for relaying of zero fee transactions.
In AcceptToMemoryPool we have:
if (fLimitFree && nFees < ::minRelayTxFee.GetFee(nSize))
{
static CCriticalSection csFreeLimiter;
static double dFreeCount;
static int64_t nLastTime;
int64_t nNow = GetTime();
LOCK(csFreeLimiter);
// Use an exponentially decaying ~10-minute window:
dFreeCount *= pow(1.0 - 1.0/600.0, (double)(nNow - nLastTime));
nLastTime = nNow;
// -limitfreerelay unit is thousand-bytes-per-minute
// At default rate it would take over a month to fill 1GB
if (dFreeCount >= GetArg("-limitfreerelay", 15)*10*1000)
return state.DoS(0, error("AcceptToMemoryPool : free transaction rejected by rate limiter"),
REJECT_INSUFFICIENTFEE, "insufficient priority");
LogPrint("mempool", "Rate limit dFreeCount: %g => %g\n", dFreeCount, dFreeCount+nSize);
dFreeCount += nSize;
}
There's no reference to tx priority; am I right in saying that all zero-fee transactions are subject to rate-limiting, regardless of their priority? I had the impression that this was not the case, given how it is often said that transactions with sufficiently high priority can be sent safely without fees.
An additional question: in the
wiki it says that "A transaction may be safely sent without fees if ... all outputs are 0.01 BTC or larger". I'm not sure where this 0.01 BTC figure comes from, I couldn't find any reference to it in the code, could someone point it out for me?
Thanks.