Skip to content

Commit 02cf4ce

Browse files
committed
Format
1 parent 8ac50dc commit 02cf4ce

File tree

2 files changed

+16
-18
lines changed

2 files changed

+16
-18
lines changed

src/ledger/LedgerManagerImpl.cpp

+14-16
Original file line numberDiff line numberDiff line change
@@ -220,8 +220,7 @@ LedgerManagerImpl::getLCLState() const
220220
return mLastClosedLedgerState;
221221
}
222222

223-
224-
LedgerManagerImpl::LedgerState &
223+
LedgerManagerImpl::LedgerState&
225224
LedgerManagerImpl::getLCLState()
226225
{
227226
releaseAssert(threadIsMain());
@@ -365,11 +364,9 @@ LedgerManagerImpl::loadLastKnownLedger(bool restoreBucketlist)
365364
{
366365
// In no-history mode, this method should only be called when
367366
// the LCL is genesis.
368-
releaseAssertOrThrow(getLCLState().ledgerHeader.hash ==
369-
lastLedgerHash);
370-
releaseAssertOrThrow(
371-
getLCLState().ledgerHeader.header.ledgerSeq ==
372-
GENESIS_LEDGER_SEQ);
367+
releaseAssertOrThrow(getLCLState().ledgerHeader.hash == lastLedgerHash);
368+
releaseAssertOrThrow(getLCLState().ledgerHeader.header.ledgerSeq ==
369+
GENESIS_LEDGER_SEQ);
373370
CLOG_INFO(Ledger, "LCL is genesis: {}",
374371
ledgerAbbrev(getLCLState().ledgerHeader));
375372
latestLedgerHeader = getLCLState().ledgerHeader.header;
@@ -425,8 +422,7 @@ LedgerManagerImpl::loadLastKnownLedger(bool restoreBucketlist)
425422
// configs right away
426423
LedgerTxn ltx(mApp.getLedgerTxnRoot());
427424
updateSorobanNetworkConfigForApply(ltx);
428-
getLCLState().sorobanConfig =
429-
mApplyState.mSorobanNetworkConfig;
425+
getLCLState().sorobanConfig = mApplyState.mSorobanNetworkConfig;
430426
}
431427
}
432428

@@ -1334,10 +1330,9 @@ LedgerManagerImpl::getLastClosedSnaphot()
13341330
{
13351331
if (!getLCLState().snapshot)
13361332
{
1337-
getLCLState().snapshot =
1338-
mApp.getBucketManager()
1339-
.getBucketSnapshotManager()
1340-
.copySearchableLiveBucketListSnapshot();
1333+
getLCLState().snapshot = mApp.getBucketManager()
1334+
.getBucketSnapshotManager()
1335+
.copySearchableLiveBucketListSnapshot();
13411336
}
13421337
return getLCLState().snapshot;
13431338
}
@@ -1612,10 +1607,12 @@ LedgerManagerImpl::applyTransactions(
16121607
// Record counts
16131608
if (numTxs > 0)
16141609
{
1615-
mLedgerApplyMetrics.mTransactionCount.Update(static_cast<int64_t>(numTxs));
1610+
mLedgerApplyMetrics.mTransactionCount.Update(
1611+
static_cast<int64_t>(numTxs));
16161612
TracyPlot("ledger.transaction.count", static_cast<int64_t>(numTxs));
16171613

1618-
mLedgerApplyMetrics.mOperationCount.Update(static_cast<int64_t>(numOps));
1614+
mLedgerApplyMetrics.mOperationCount.Update(
1615+
static_cast<int64_t>(numOps));
16191616
TracyPlot("ledger.operation.count", static_cast<int64_t>(numOps));
16201617
CLOG_INFO(Tx, "applying ledger {} ({})",
16211618
ltx.loadHeader().current().ledgerSeq, txSet.summary());
@@ -1707,7 +1704,8 @@ LedgerManagerImpl::applyTransactions(
17071704

17081705
mLedgerApplyMetrics.mTransactionApplySucceeded.inc(txSucceeded);
17091706
mLedgerApplyMetrics.mTransactionApplyFailed.inc(txFailed);
1710-
mLedgerApplyMetrics.mSorobanTransactionApplySucceeded.inc(sorobanTxSucceeded);
1707+
mLedgerApplyMetrics.mSorobanTransactionApplySucceeded.inc(
1708+
sorobanTxSucceeded);
17111709
mLedgerApplyMetrics.mSorobanTransactionApplyFailed.inc(sorobanTxFailed);
17121710
logTxApplyMetrics(ltx, numTxs, numOps);
17131711
return txResultSet;

src/ledger/LedgerManagerImpl.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -112,8 +112,8 @@ class LedgerManagerImpl : public LedgerManager
112112
// is currently closing a ledger or has ledgers queued to apply.
113113
bool mCurrentlyApplyingLedger{false};
114114

115-
LedgerState &getLCLState();
116-
LedgerState const&getLCLState() const;
115+
LedgerState& getLCLState();
116+
LedgerState const& getLCLState() const;
117117

118118
static std::vector<MutableTxResultPtr> processFeesSeqNums(
119119
ApplicableTxSetFrame const& txSet, AbstractLedgerTxn& ltxOuter,

0 commit comments

Comments
 (0)