Skip to content
Bitcoin Roots

v29.4-roots.4 · Commit 3: [PATCH 03/37] policy: restore conservative relay and network controls

src/policy/fees.h

Before: src/policy/fees.h · After: src/policy/fees.h

File metadata
index a95cc19dd45fce0c04567ddc8a44636f1688dd17..b3671aa23204009ae4ea9607f59954f55deaed3b 100644

Download original patch · Release notes

Diff rows 1–23 of 23. Line numbers refer to the original before/after files.

+ Added− RemovedUnmarked lines are context.

Scroll the code area horizontally to read long lines. Before is on the left; after is on the right. Unified view fits narrow screens more easily.

src/policy/fees.h CHANGED
@@ -147,7 +147,7 @@ struct FeeCalculation
147
  */
148
  class CBlockPolicyEstimator : public CValidationInterface
149
  {
150
- private:
151
  /** Track confirm delays up to 12 blocks for short horizon */
152
  static constexpr unsigned int SHORT_BLOCK_PERIODS = 12;
153
  static constexpr unsigned int SHORT_SCALE = 1;
@@ -157,6 +157,7 @@ private:
157
  /** Track confirm delays up to 1008 blocks for long horizon */
158
  static constexpr unsigned int LONG_BLOCK_PERIODS = 42;
159
  static constexpr unsigned int LONG_SCALE = 24;
 
160
  /** Historical estimates that are older than this aren't valid */
161
  static const unsigned int OLDEST_ESTIMATE_HISTORY = 6 * 1008;
162
 
@@ -256,7 +257,7 @@ public:
256
  EXCLUSIVE_LOCKS_REQUIRED(!m_cs_fee_estimator);
257
 
258
  /** Record current fee estimations. */
259
- void FlushFeeEstimates()
260
  EXCLUSIVE_LOCKS_REQUIRED(!m_cs_fee_estimator);
261
 
262
  /** Calculates the age of the file, since last modified */
 
147
  */
148
  class CBlockPolicyEstimator : public CValidationInterface
149
  {
150
+ public:
151
  /** Track confirm delays up to 12 blocks for short horizon */
152
  static constexpr unsigned int SHORT_BLOCK_PERIODS = 12;
153
  static constexpr unsigned int SHORT_SCALE = 1;
 
157
  /** Track confirm delays up to 1008 blocks for long horizon */
158
  static constexpr unsigned int LONG_BLOCK_PERIODS = 42;
159
  static constexpr unsigned int LONG_SCALE = 24;
160
+ private:
161
  /** Historical estimates that are older than this aren't valid */
162
  static const unsigned int OLDEST_ESTIMATE_HISTORY = 6 * 1008;
163
 
 
257
  EXCLUSIVE_LOCKS_REQUIRED(!m_cs_fee_estimator);
258
 
259
  /** Record current fee estimations. */
260
+ bool FlushFeeEstimates() const
261
  EXCLUSIVE_LOCKS_REQUIRED(!m_cs_fee_estimator);
262
 
263
  /** Calculates the age of the file, since last modified */