adm/frostfsid: Remove unreachable condition
Some checks failed
DCO action / DCO (pull_request) Failing after 1m37s
Tests and linters / Run gofumpt (pull_request) Successful in 1m49s
Vulncheck / Vulncheck (pull_request) Successful in 2m41s
Build / Build Components (pull_request) Successful in 3m20s
Pre-commit hooks / Pre-commit (pull_request) Successful in 3m22s
Tests and linters / gopls check (pull_request) Successful in 4m6s
Tests and linters / Staticcheck (pull_request) Successful in 4m27s
Tests and linters / Lint (pull_request) Successful in 4m59s
Tests and linters / Tests (pull_request) Successful in 6m29s
Tests and linters / Tests with -race (pull_request) Successful in 7m10s

SendConsensusTx() modifies SendTxs field, if it is not the case, there
is a bug in code.

Signed-off-by: Evgenii Stratonikov <e.stratonikov@yadro.com>
This commit is contained in:
Evgenii Stratonikov 2024-11-22 13:19:58 +03:00
parent 50945caf57
commit 4a19ed5565
Signed by: fyrchik
SSH key fingerprint: SHA256:m/TTwCzjnRkXgnzEx9X92ccxy1CcVeinOgDb3NPWWmg

View file

@ -1,7 +1,6 @@
package frostfsid
import (
"errors"
"fmt"
"math/big"
"sort"
@ -489,10 +488,6 @@ func (f *frostfsidClient) sendWaitRes() (*state.AppExecResult, error) {
}
f.bw.Reset()
if len(f.wCtx.SentTxs) == 0 {
return nil, errors.New("no transactions to wait")
}
f.wCtx.Command.Println("Waiting for transactions to persist...")
return f.roCli.Wait(f.wCtx.SentTxs[0].Hash, f.wCtx.SentTxs[0].Vub, nil)
}