@@ -204,7 +204,7 @@ struct mempoolentry_txid
204204class CompareTxMemPoolEntryByDescendantScore
205205{
206206public:
207- bool operator ()(const CTxMemPoolEntry& a, const CTxMemPoolEntry& b)
207+ bool operator ()(const CTxMemPoolEntry& a, const CTxMemPoolEntry& b) const
208208 {
209209 bool fUseADescendants = UseDescendantScore (a);
210210 bool fUseBDescendants = UseDescendantScore (b);
@@ -226,7 +226,7 @@ class CompareTxMemPoolEntryByDescendantScore
226226 }
227227
228228 // Calculate which score to use for an entry (avoiding division).
229- bool UseDescendantScore (const CTxMemPoolEntry &a)
229+ bool UseDescendantScore (const CTxMemPoolEntry &a) const
230230 {
231231 double f1 = (double )a.GetModifiedFee () * a.GetSizeWithDescendants ();
232232 double f2 = (double )a.GetModFeesWithDescendants () * a.GetTxSize ();
@@ -241,7 +241,7 @@ class CompareTxMemPoolEntryByDescendantScore
241241class CompareTxMemPoolEntryByScore
242242{
243243public:
244- bool operator ()(const CTxMemPoolEntry& a, const CTxMemPoolEntry& b)
244+ bool operator ()(const CTxMemPoolEntry& a, const CTxMemPoolEntry& b) const
245245 {
246246 double f1 = (double )a.GetModifiedFee () * b.GetTxSize ();
247247 double f2 = (double )b.GetModifiedFee () * a.GetTxSize ();
@@ -255,7 +255,7 @@ class CompareTxMemPoolEntryByScore
255255class CompareTxMemPoolEntryByEntryTime
256256{
257257public:
258- bool operator ()(const CTxMemPoolEntry& a, const CTxMemPoolEntry& b)
258+ bool operator ()(const CTxMemPoolEntry& a, const CTxMemPoolEntry& b) const
259259 {
260260 return a.GetTime () < b.GetTime ();
261261 }
0 commit comments