Skip to content

Commit ec2908e

Browse files
committed
Only load auto_sync = 1 tables if [auto_sync] in cfg is 1
1 parent 411c2c8 commit ec2908e

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/peersafe/app/table/impl/TableSync.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -908,6 +908,11 @@ void TableSync::CreateTableItems()
908908
}
909909

910910
//2.read from state table
911+
if (!bAutoLoadTable_)
912+
{
913+
//if auto_sync=0, will not load db tables with field auto_sync = 1
914+
return;
915+
}
911916
auto ledger = app_.getLedgerMaster().getValidatedLedger();
912917
//read chainId
913918
uint256 chainId = TableSyncUtil::GetChainId(ledger.get());

0 commit comments

Comments
 (0)