Changeset View
Changeset View
Standalone View
Standalone View
src/miner.cpp
Show First 20 Lines • Show All 489 Lines • ▼ Show 20 Lines | while (mi != mempool->mapTx.get<ancestor_score>().end() || | ||||
if (mi == mempool->mapTx.get<ancestor_score>().end()) { | if (mi == mempool->mapTx.get<ancestor_score>().end()) { | ||||
// We're out of entries in mapTx; use the entry from mapModifiedTx | // We're out of entries in mapTx; use the entry from mapModifiedTx | ||||
iter = modit->iter; | iter = modit->iter; | ||||
fUsingModified = true; | fUsingModified = true; | ||||
} else { | } else { | ||||
// Try to compare the mapTx entry to the mapModifiedTx entry. | // Try to compare the mapTx entry to the mapModifiedTx entry. | ||||
iter = mempool->mapTx.project<0>(mi); | iter = mempool->mapTx.project<0>(mi); | ||||
if (modit != mapModifiedTx.get<ancestor_score>().end() && | if (modit != mapModifiedTx.get<ancestor_score>().end() && | ||||
CompareModifiedEntry()(*modit, CTxMemPoolModifiedEntry(iter))) { | CompareTxMemPoolEntryByAncestorFee()( | ||||
*modit, CTxMemPoolModifiedEntry(iter))) { | |||||
// The best entry in mapModifiedTx has higher score than the one | // The best entry in mapModifiedTx has higher score than the one | ||||
// from mapTx. Switch which transaction (package) to consider | // from mapTx. Switch which transaction (package) to consider | ||||
iter = modit->iter; | iter = modit->iter; | ||||
fUsingModified = true; | fUsingModified = true; | ||||
} else { | } else { | ||||
// Either no entry in mapModifiedTx, or it's worse than mapTx. | // Either no entry in mapModifiedTx, or it's worse than mapTx. | ||||
// Increment mi for the next loop iteration. | // Increment mi for the next loop iteration. | ||||
++mi; | ++mi; | ||||
▲ Show 20 Lines • Show All 208 Lines • Show Last 20 Lines |