forked from TrueCloudLab/frostfs-node
[#1633] neofs-adm: Start chain only on happy path
If the error is returned, it will not be closed properly. Signed-off-by: Evgenii Stratonikov <evgeniy@morphbits.ru>
This commit is contained in:
parent
642d7328ab
commit
38558a3238
1 changed files with 2 additions and 1 deletions
|
@ -54,7 +54,6 @@ func newLocalClient(v *viper.Viper, wallets []*wallet.Wallet) (*localClient, err
|
|||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
defer func() { go bc.Run() }()
|
||||
|
||||
m := smartcontract.GetDefaultHonestNodeCount(cfg.ProtocolConfiguration.ValidatorsCount)
|
||||
accounts := make([]*wallet.Account, len(wallets))
|
||||
|
@ -81,6 +80,8 @@ func newLocalClient(v *viper.Viper, wallets []*wallet.Wallet) (*localClient, err
|
|||
return bytes.Compare(pi, pj) == -1
|
||||
})
|
||||
|
||||
go bc.Run()
|
||||
|
||||
return &localClient{
|
||||
bc: bc,
|
||||
dumpPath: v.GetString(localDumpFlag),
|
||||
|
|
Loading…
Reference in a new issue